Testing functions with expect()
Expectations on times a function is called
Functions\expect('paganini')->once();
Functions\expect('tween')->twice();
Functions\expect('who_knows')->zeroOrMoreTimes();
Functions\expect('i_should_run')->atLeast()->once();
Functions\expect('i_have_a_max')->atMost()->twice();
Functions\expect('poor_me')->never();
Functions\expect('pretty_precise')->times(3);
Functions\expect('i_have_max_and_min')->between(2, 4);Expectations on received arguments
Forcing behavior
Last updated