- Objective - To implement an
ItemSorter
which returns an array ofItem
objects sorted by the respective field. - Purpose - To establish familiarity with:
- Interfaces
Comparator<T>
- Write method definitions for
Item
class. - Ensure 100% success rate of each test class in
test.rocks.zipcode.io.item
- Implement
Comparator
interface for each class in the packagesrc.rocks.zipcode.io.comparators
.- Ensure the
Comparator
is parameterized with typeItem
- Ensure the
- Write method definitions for each
Comparator
. - Ensure 100% success rate of each test class in
test.rocks.zipcode.io.comparators
.
- Write method definitions for
ItemSorter
- Ensure 100% success rate of each test class in
test.rocks.zipcode.io.itemsorter
.
- Using
SortByIdTest
andSortByNameTest
as example classes, write test at least 3 cases forSortByPriceTest
. - Verify with classmates that your tests are comprehensive, and covering the correct aspect of the program.