I am making use of ManualResetEvent
class in a test.
Basically, I want to invoke the Set()
method when a particular function is called.
This looks like:
var mre = new ManualResetEvent(false);
mockObj.Setup(dmc => dmc.Foo(param1, param2, param3)).Callback(mre.Set()); //Error here.
However, I get an error saying:
Cannot convert from bool to 'System.Action'
when I try to set the mre
.
Am I doing anything wrong here?