Navigation
API > API/Runtime > API/Runtime/Engine > API/Runtime/Engine/Tests
References
| Module | Engine |
| Header | /Engine/Source/Runtime/Engine/Public/Tests/NetTestHelpers.h |
| Include | #include "Tests/NetTestHelpers.h" |
Syntax
struct FTestWorlds
Remarks
Stores FTestWorldInstances for a server and clients and allows synchronously ticking them. Can be used within a single function to make automated tests that use the whole world & net driver flow.
Variables
| Type | Name | Description | |
|---|---|---|---|
| TArray< FTestWorldInstance > | Clients | ||
| FTestWorldInstance | Server | Server and Client Worlds |
Constructors
| Type | Name | Description | |
|---|---|---|---|
FTestWorlds
(
const TCHAR* ServerURL, |
Creates a server world using the given URL. |
Destructors
| Type | Name | Description | |
|---|---|---|---|
~FTestWorlds () |
Functions
| Type | Name | Description | |
|---|---|---|---|
| bool | |||
| UObject * | FindReplicatedObjectOnClient
(
UObject* ServerObject, |
Find the remote instance of a replicated object. | |
| APlayerController * | GetServerPlayerControllerOfClient
(
uint32 ClientIndex |
Return the Server's player state corresponding to a specific client | |
| void | Ticks all server & client worlds NumTick times synchronously. | ||
| bool | TickAllUntil
(
const PredicateT& Predicate, |
Inline functions. | |
| void | TickClients () |
||
| void | TickClientsAndDelay
(
uint32 NumFramesToDelay |
||
| void | |||
| void | TickServer () |
||
| void | TickServerAndDelay
(
uint32 NumFramesToDelay |
Tick the world but delay the packets that would be sent | |
| void | Tick the world and drop all outgoing packets | ||
| bool | WaitForClientConnect
(
FTestWorldInstance& Client |
Ticks all server & client worlds until the passed in client world has a valid client PlayerController. |