OpenPetra
Free Administration Software for Non-Profits
Ict.Testing.NUnitTools.TNUnitEventAsserter Class Reference

To be used in connection with Class TNUnitEventHandlerCheck<T> for easy asserting of Events. More...

Static Public Member Functions

static void Assert< TEventArgs > (TNUnitEventHandlerCheck< TEventArgs >AEventCapturer, Action< TNUnitEventHandlerCheck< TEventArgs > >AEventTest, Action ACodeToRun)
 Convenient way of writing an Assert that checks whether an Event got raised, or not. More...
 
static Action< TNUnitEventHandlerCheck< TEventArgs > > GotRaised< TEventArgs > ()
 Use this Method to check whether the Event in question got raised. More...
 
static Action< TNUnitEventHandlerCheck< TEventArgs > > DidNotGetRaised< TEventArgs > ()
 Use this Method to check whether the Event in question did not get raised. More...
 

Detailed Description

To be used in connection with Class TNUnitEventHandlerCheck<T> for easy asserting of Events.

Member Function Documentation

◆ Assert< TEventArgs >()

static void Ict.Testing.NUnitTools.TNUnitEventAsserter.Assert< TEventArgs > ( TNUnitEventHandlerCheck< TEventArgs >  AEventCapturer,
Action< TNUnitEventHandlerCheck< TEventArgs > >  AEventTest,
Action  ACodeToRun 
)
inlinestatic

Convenient way of writing an Assert that checks whether an Event got raised, or not.

Parameters
AEventCapturerTNUnitEventHandlerCheck<T> instance.
AEventTestEvent test that should be executed.
ACodeToRunCode that is to be executed that should/shouldn't raise the Event.
Type Constraints
TEventArgs :EventArgs 

◆ DidNotGetRaised< TEventArgs >()

static Action< TNUnitEventHandlerCheck< TEventArgs > > Ict.Testing.NUnitTools.TNUnitEventAsserter.DidNotGetRaised< TEventArgs > ( )
inlinestatic

Use this Method to check whether the Event in question did not get raised.

Returns
Assert that is used as input for the Assert Method.
Type Constraints
TEventArgs :EventArgs 

◆ GotRaised< TEventArgs >()

static Action< TNUnitEventHandlerCheck< TEventArgs > > Ict.Testing.NUnitTools.TNUnitEventAsserter.GotRaised< TEventArgs > ( )
inlinestatic

Use this Method to check whether the Event in question got raised.

Returns
Assert that is used as input for the Assert Method.
Type Constraints
TEventArgs :EventArgs 

The documentation for this class was generated from the following file: