Hi all,
I have a quick question. Is this a proper way of using blackbox testing to test the stringTokenizer class? If not, would you provide a proper example that displays the pass or fail.
string = "cat, dog";
StringTokenizer token = new StringTokenizer(string, ",");
if (token.countTokens() == 2)
System.out.println("Passed");
else {
System.out.println("Fail");
}
Thanks, KimJack