Tests: reuse CreateNetworked

This commit is contained in:
vis2k 2021-08-11 14:11:37 +08:00
parent e36a9a16fb
commit f0441738d0

View File

@ -22,7 +22,7 @@ public override IEnumerator UnitySetUp()
[UnityTest]
public IEnumerator DestroyPlayerForConnectionTest()
{
GameObject player = new GameObject("testPlayer", typeof(NetworkIdentity));
CreateNetworked(out GameObject player, out _);
NetworkConnectionToClient conn = new NetworkConnectionToClient(1);
NetworkServer.AddPlayerForConnection(conn, player);