voben
01/23/2020, 4:47 AMevery {} returns something
and
every {} answers {something}
streetsofboston
01/23/2020, 5:23 AMsomething
is evaluated only once and immediately.
The 2nd example does not evaluate something
immediately and will evaluate it later, each time when the mocked method is called.viralshah
01/23/2020, 5:26 AManswers
clause where as returns
takes an actual resultivano
01/23/2020, 7:19 AManswers
was for the callbacks onlys1m0nw1
01/23/2020, 8:38 AManswers
to access the passed in parameters to respond with a specialized return valueLeoColman
01/23/2020, 1:59 PMLeoColman
01/23/2020, 2:00 PMevery {} answers { println("Mock!"); something }