I'm trying to write getter and setter mock methods which seem to be doing some database operation internally. Getter returns a String and setter takes String as argument. I would like to pass whatever I get from getter to the setter instead of passing a mock String so as to keep track of data flow.
Is there a way to pass the same String what actual setter is getting, to the mock method.
Please direct if there's a solution already available for this.