- See also
- TestKit
extension class
More...
|
new TestActorRef< TActor > | ActorOfAsTestActorRef< TActor > (Expression< Func< TActor >> factory, string name=null) |
| Create a new actor as child of ActorSystem and returns it as TestActorRef<TActor> to enable access to the underlying actor instance via TestActorRefBase<TActor>.UnderlyingActor. Uses an expression that calls the constructor of TActor . More...
|
|
new TestActorRef< TActor > | ActorOfAsTestActorRef< TActor > (Props props, string name=null) |
| Create a new actor as child of ActorSystem and returns it as TestActorRef<TActor> to enable access to the underlying actor instance via TestActorRefBase<TActor>.UnderlyingActor. Uses an expression that calls the constructor of TActor . More...
|
|
virtual void | Cleanup () |
| Cleanup after test run More...
|
|
- See also
- TestKit
extension class
- Template Parameters
-
TConfigurator | Class, that describes test configuration |
Definition at line 34 of file BaseActorTest.cs.
◆ BaseActorTest()
◆ ActorOfAsTestActorRef< TActor >() [1/2]
Create a new actor as child of ActorSystem and returns it as TestActorRef<TActor> to enable access to the underlying actor instance via TestActorRefBase<TActor>.UnderlyingActor. Uses an expression that calls the constructor of TActor .
ActorOf<MyActor>(()=>new MyActor("value", 4711), "test-actor")
- Template Parameters
-
TActor | The type of the actor. |
- Parameters
-
factory | An expression that calls the constructor of TActor |
name | Optional: The name. |
- Returns
- The actor ref
Definition at line 68 of file BaseActorTest.cs.
◆ ActorOfAsTestActorRef< TActor >() [2/2]
Create a new actor as child of ActorSystem and returns it as TestActorRef<TActor> to enable access to the underlying actor instance via TestActorRefBase<TActor>.UnderlyingActor. Uses an expression that calls the constructor of TActor .
ActorOf<MyActor>(()=>new MyActor("value", 4711), "test-actor")
- Template Parameters
-
TActor | The type of the actor. |
- Parameters
-
props | The props to create an actor TActor |
name | Optional: The name. |
- Returns
- The actor ref
Definition at line 95 of file BaseActorTest.cs.
◆ Cleanup()
◆ Dispose()
◆ ExpectMsg< T >() [1/2]
Waiting for message
- See also
- TestActorForwarder
that was sent to the specified address
- Parameters
-
- Template Parameters
-
T | The original message type |
- Returns
- The original message
Definition at line 139 of file BaseActorTest.cs.
◆ ExpectMsg< T >() [2/2]
Waiting for message
- See also
- TestActorForwarder
that was sent to the specified address on specified time
- Parameters
-
path | specified address |
timeout | Timespan when message should arrive |
- Template Parameters
-
T | The original message type |
It is supposed that between now and timespan they will be now messages, and message should arrive exactly at specified time
- Returns
- The original message
Definition at line 166 of file BaseActorTest.cs.
◆ ExpectNoTestMsg()
◆ ExpectTestMsg< T >() [1/2]
◆ ExpectTestMsg< T >() [2/2]
Waiting for message
- See also
- TestActorForwarder
that was sent on specified time
- Parameters
-
timeout | Timespan when message should arrive |
- Template Parameters
-
T | The original message type |
- Returns
- The TestMessage<T>.
It is supposed that between now and timespan they will be now messages, and message should arrive exactly at specified time
Definition at line 230 of file BaseActorTest.cs.
The documentation for this class was generated from the following file: