Anybody tries to set
test cases for this task below:
When the argument passed to the method is null it returns an empty
string • When the string has exactly one character the same string is returned When the string is longer then 1 character its nice version is returned. Examples of invert method usage nice.change("x"); // returns "x" // returns in nice.change(null); nice.change("KY"); // return "YK" Requirements • Your task is to implement a suite of tests in
JUnit 4 that will test all the possible behaviours of the invert method, as described above. Your suite of tests will be run against multiple (wrong and correct) implementations of invert method.
Your quick feedback would be highly appreciated.