I follow the method specified in Roy Osherov’s book “The Art of Testing Unit”, while the name testing methods are MethodName_Scenario_Expectation . It is great for my "single" tests. But for the tests that I write in the controller or coordinator class, there is no need for a method that I want to test.
For these tests, I create several conditions that make up one scenario, and then check the wait. For example, I can set some properties in different instances, generate an event, and then check if my expectation from the controller / coordinator is fulfilled. Now my controller processes events using a private event handler. My scenario here is that I set some properties, say 3
condition1, condition2 and condition 3
Also in my script there is
event raised
I do not have a method name, since my event handler is private. What is the name of this testing method?
source
share