i have such java codes:
public class A {
public int get() {
// many codes
String s = new String();
//...
int n = 5;
return isEmpty(s) ? n : -1;
}
public boolean isEmpty(String s) {
return s.isEmpty();
}
}
now i want to just test get(), i don't want to test isEmpty() at the same, so i want to mock isEmpty(), just test a method, if it invokes another method of the class, can easymock mock the method?