mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
change Debug.Assert to Assert.That
This commit is contained in:
parent
2ab395cc85
commit
b434d001b1
@ -864,14 +864,14 @@ public void AuthorityIsFalseVariations()
|
||||
identity.isServer = false;
|
||||
identity.isOwned = false;
|
||||
emptyBehaviour.syncDirection = SyncDirection.ClientToServer;
|
||||
Debug.Assert(!emptyBehaviour.authority, "Client-only isOwned=false syncDirection=ClientToServer should have no authority");
|
||||
Assert.That(!emptyBehaviour.authority, "Client-only isOwned=false syncDirection=ClientToServer should have no authority");
|
||||
|
||||
CreateNetworked(out _, out identity, out emptyBehaviour);
|
||||
identity.isClient = true;
|
||||
identity.isServer = false;
|
||||
identity.isOwned = false;
|
||||
emptyBehaviour.syncDirection = SyncDirection.ServerToClient;
|
||||
Debug.Assert(!emptyBehaviour.authority, "Client-only isOwned=false syncDirection=ServerToClient should have no authority");
|
||||
Assert.That(!emptyBehaviour.authority, "Client-only isOwned=false syncDirection=ServerToClient should have no authority");
|
||||
|
||||
// has no authority as server only
|
||||
CreateNetworked(out _, out identity, out emptyBehaviour);
|
||||
@ -879,7 +879,7 @@ public void AuthorityIsFalseVariations()
|
||||
identity.isServer = true;
|
||||
identity.isOwned = false;
|
||||
emptyBehaviour.syncDirection = SyncDirection.ClientToServer;
|
||||
Debug.Assert(!emptyBehaviour.authority, "Server-only isOwned=false syncDirection=ClientToServer should have no authority");
|
||||
Assert.That(!emptyBehaviour.authority, "Server-only isOwned=false syncDirection=ClientToServer should have no authority");
|
||||
|
||||
// has no authority as host, not owned and client-to-server sync
|
||||
CreateNetworked(out _, out identity, out emptyBehaviour);
|
||||
@ -887,7 +887,7 @@ public void AuthorityIsFalseVariations()
|
||||
identity.isServer = true;
|
||||
identity.isOwned = false;
|
||||
emptyBehaviour.syncDirection = SyncDirection.ClientToServer;
|
||||
Debug.Assert(!emptyBehaviour.authority, "Host isOwned=false syncDirection=ClientToServer should have no authority");
|
||||
Assert.That(!emptyBehaviour.authority, "Host isOwned=false syncDirection=ClientToServer should have no authority");
|
||||
}
|
||||
|
||||
[Test]
|
||||
@ -899,7 +899,7 @@ public void AuthorityIsTrueVariations()
|
||||
identity.isServer = false;
|
||||
identity.isOwned = true;
|
||||
emptyBehaviour.syncDirection = SyncDirection.ClientToServer;
|
||||
Debug.Assert(emptyBehaviour.authority, "Client-only isOwned=true syncDirection=ClientToServer should have authority");
|
||||
Assert.That(emptyBehaviour.authority, "Client-only isOwned=true syncDirection=ClientToServer should have authority");
|
||||
|
||||
// has authority as server only
|
||||
CreateNetworked(out _, out identity, out emptyBehaviour);
|
||||
@ -907,7 +907,7 @@ public void AuthorityIsTrueVariations()
|
||||
identity.isServer = true;
|
||||
identity.isOwned = false;
|
||||
emptyBehaviour.syncDirection = SyncDirection.ServerToClient;
|
||||
Debug.Assert(emptyBehaviour.authority, "Server-only isOwned=false syncDirection=ServerToClient should have authority");
|
||||
Assert.That(emptyBehaviour.authority, "Server-only isOwned=false syncDirection=ServerToClient should have authority");
|
||||
|
||||
// has authority as host, owned and client-to-server sync
|
||||
CreateNetworked(out _, out identity, out emptyBehaviour);
|
||||
@ -915,7 +915,7 @@ public void AuthorityIsTrueVariations()
|
||||
identity.isServer = true;
|
||||
identity.isOwned = true;
|
||||
emptyBehaviour.syncDirection = SyncDirection.ClientToServer;
|
||||
Debug.Assert(emptyBehaviour.authority, "Host isOwned=true syncDirection=ClientToServer should have authority");
|
||||
Assert.That(emptyBehaviour.authority, "Host isOwned=true syncDirection=ClientToServer should have authority");
|
||||
|
||||
// has authority as host, not owned and server-to-client sync
|
||||
CreateNetworked(out _, out identity, out emptyBehaviour);
|
||||
@ -923,7 +923,7 @@ public void AuthorityIsTrueVariations()
|
||||
identity.isServer = true;
|
||||
identity.isOwned = false;
|
||||
emptyBehaviour.syncDirection = SyncDirection.ServerToClient;
|
||||
Debug.Assert(emptyBehaviour.authority, "Host isOwned=false syncDirection=ServerToClient should have authority");
|
||||
Assert.That(emptyBehaviour.authority, "Host isOwned=false syncDirection=ServerToClient should have authority");
|
||||
}
|
||||
|
||||
// test for an issue where nested classes wouldn't be weaved.
|
||||
|
Loading…
Reference in New Issue
Block a user