I have a method called mainMethod()
and it returns a promise.
This method contains several methods m1()
, m2()
...,m5()
.
Now I am making a unit test using sinon
,
I want to check if m1()
is called and m2()
is not called.
Because I have an array that not empty after m1()
is called but it will be empty after m2()
is called.
I want to make a check or test after m1()
is called and before m2()
is called.
Is it possible using sinon
?