Mocker.expect

Record new expectation that will exactly match method called in methodCall argument

Returns an object that allows you to set various properties of the expectation, such as return value, number of repetitions or matching options.

class Mocker
expect
(
T
)
(
lazy T methodCall
)

Examples

Mocker m = new Mocker;
Object o = m.Mock!(Object);
m.expect(o.toString).returns("hello?");

Meta