![]() |
public boolean process() int i = fieldCustomer_Name.length();//1 try return errors.isEmpty(); //8 |
Test Path (1): for path 1
Variable values: i>1 && (Character.isLetter(char) == true || Character.isWhiteSpace(char)
== true || fieldCustomer_Name.char(i-1) == ¡®/¡¯
Expected results:
? No error message
? Decrement of value i
? Return true boolean for valid credit card number
Test Path (2): for path 2
Variable values: i>1 && (Character.isLetter(char) == false &&
Character.isWhiteSpace(char) == false && fieldCustomer_Name.char(i-1)
!= ¡®/¡¯
Expected results:
? Error message on customer name input
? Return false boolean for invalid customer name input
Test Path (3): for path 3
Variable values: i < 1
Expected results:
? Error message for empty input
? Return false boolean for invalid input