* Issue #253: Tried to improve grade school structure. Removed .db() function, added numberOfStudents functions and renamed the sort function to studentsByGradeAlphabetical. Added test to check that grade() gets the students in the order they were inserted. Removed getsStudentsInAGrade() test as what it was testing was already being covered by the tests before it.
* Added tests for protection agains mutation of the list object
* Issue #253: Make the sort test more generic. This to allow a broader range of implementations. Currently users are hindered into return the type HashMap<Integer, List<String>. This test update will check the order of any Map that maps to any Collection value type. This opens the doors for more possible types of solutions.
Issue #253: Tried to improve grade school structure. (#259)
* Issue #253: Tried to improve grade school structure. Removed .db() function, added numberOfStudents functions and renamed the sort function to studentsByGradeAlphabetical. Added test to check that grade() gets the students in the order they were inserted. Removed getsStudentsInAGrade() test as what it was testing was already being covered by the tests before it.
* Added tests for protection agains mutation of the list object
Issue #253: Make the sort test more generic. This to allow a broader range of implementations. Currently users are hindered into return the type HashMap<Integer, List<String>. This test update will check the order of any Map that maps to any Collection value type. This opens the doors for more possible types of solutions. (#269)
Review markups. Changed assertion order, test names and position of Ignore in MatrixExercise. Changed Integer.valueOf to Integer.parseInt in Matrix. Changed String.split to using Pattern in Matrix.
Invoke JUnit assertEquals with Argument Order (expected, actual)
The JUnit API documents assertEquals as taking the expected argument
before the actual argument. Failure to adhere to this can result in
very confusing test failure messages.
For example in testTransformOneValue 'old' contains 'A' and 'expected'
contains 'a'. If the implementer does not lower-case the key, the
failure message is as follows if the argument order is
(actual, expected):
EtlTest > testTransformOneValue FAILED
java.lang.AssertionError: expected:<{A=1}> but was:<{a=1}>
at org.junit.Assert.fail(Assert.java:88)
at org.junit.Assert.failNotEquals(Assert.java:834)
at org.junit.Assert.assertEquals(Assert.java:118)
at org.junit.Assert.assertEquals(Assert.java:144)
at EtlTest.testTransformOneValue(EtlTest.java:27)
This is very confusing as "was:<{a=1}>" is exactly what we were hoping
the result would be.
Issue #152: Made simple-cipher more approachable (#224)
* Issue #152: Made simple-cipher more approachable by splitting test classes in a more sensible way and making clear which steps they relate to.
* Changed SimpleCipherTest to use the junit Rule annotation for expected exceptions. Changed variable names in SimpleCipherTest to be more descriptive and moved the test cipherThrowsWithEmptyKey from step three to step two.
* Added HINT.md which explains how to run only one test class.
* Changed HINT.md in simple-cipher to refer to the actual test file names and not to contain the same information as in SETUP.md