TextConverter.java
/**
     *  tests actionReverse method with various cases to ensure it is working
     *  correctly.
     */
tests actionReverse method with various cases to ensure it is working
correctly.
tests actionReverse method with various cases to ensure it is working correctly .
public static void testActionCaesar() {
        boolean error = false;
        String input1 = "gotIt";
        String expected1 = "fnsHs";
        String result1 = actionCaesar( input1);
        if ( !result1.equals( expected1)) {
            error = true;
            System.out.println("1) testActionCaesar with input " + input1 + ", expected: " +
                    expected1 + " but result: " + result1);
        }
        String input2 ="CS 200";
        String expected2 = "BR 200";
        String result2 = actionCaesar(input2);
        if ( !result2.equals( expected2)) {
            error = true;
            System.out.println("2) testActionCaesar with input " + input2 + ", expected: " +
                    expected2 + " but result: " + result2);
        }
        String input3 = "aaAA";
        String expected3 = "zzZZ";
        String result3 = actionCaesar(input3);
        if ( !result3.equals( expected3)) {
            error = true;
            System.out.println("3) testActionCaesar with input " + input3 + ", expected: " +
                    expected3 + " but result: " + result3);
        }
        if ( error) {
            System.out.println( "testActionCaesar failed");
        } else {
            System.out.println("testActionCaesar passed");
        }
    }
public static void testActionCaesar ( ) { boolean error = false ; String input1 = "gotIt" ; String expected1 = "fnsHs" ; String result1 = actionCaesar ( input1 ) ; if ( ! result1 . equals ( expected1 ) ) { error = true ; System . out . println ( "1) testActionCaesar with input " + input1 + ", expected: " + expected1 + " but result: " + result1 ) ; } String input2 = "CS 200" ; String expected2 = "BR 200" ; String result2 = actionCaesar ( input2 ) ; if ( ! result2 . equals ( expected2 ) ) { error = true ; System . out . println ( "2) testActionCaesar with input " + input2 + ", expected: " + expected2 + " but result: " + result2 ) ; } String input3 = "aaAA" ; String expected3 = "zzZZ" ; String result3 = actionCaesar ( input3 ) ; if ( ! result3 . equals ( expected3 ) ) { error = true ; System . out . println ( "3) testActionCaesar with input " + input3 + ", expected: " + expected3 + " but result: " + result3 ) ; } if ( error ) { System . out . println ( "testActionCaesar failed" ) ; } else { System . out . println ( "testActionCaesar passed" ) ; } }
tests actionReverse method with various cases to ensure it is working
  correctly.
tests actionReverse method with various cases to ensure it is working correctly .