Skip to content

Commit 7892489

Browse files
committed
Fix test missing prefix
1 parent 2b60fd1 commit 7892489

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

com.unity.netcode.gameobjects/Runtime/Core/NetworkObject.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2523,10 +2523,10 @@ internal bool ApplyNetworkParenting(bool removeParent = false, bool ignoreNotSpa
25232523
}
25242524
}
25252525

2526-
// If we are removing the parent or our latest parent is not set, then remove the parent
2526+
// If we are removing the parent or our latest parent is not set, then remove the parent.
25272527
// removeParent is only set when:
25282528
// - The server-side NetworkObject.OnTransformParentChanged is invoked and the parent is being removed
2529-
// - The client-side when handling a ParentSyncMessage
2529+
// - The client-side is handling a ParentSyncMessage
25302530
// When clients are synchronizing only the m_LatestParent.HasValue will not have a value if there is no parent
25312531
// or a parent was removed prior to the client connecting (i.e. in-scene placed NetworkObjects)
25322532
if (removeParent || !m_LatestParent.HasValue)

testproject/Assets/Tests/Runtime/PrefabExtendedTests.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -336,8 +336,7 @@ public IEnumerator TestsInstantiateAndSpawnErrors([Values] InstantiateAndSpawnMe
336336
// The not listening error can only happen when trying to instantiate and spawn on a Network Prefab
337337
if (instantiateAndSpawnType == InstantiateAndSpawnMethods.NetworkObject)
338338
{
339-
//CHECK this is not being hit by tests
340-
LogAssert.Expect(LogType.Error, NetworkSpawnManager.InstantiateAndSpawnErrors[NetworkSpawnManager.InstantiateAndSpawnErrorTypes.NoActiveSession]);
339+
LogAssert.Expect(LogType.Error, $"[Netcode] {NetworkSpawnManager.InstantiateAndSpawnErrors[NetworkSpawnManager.InstantiateAndSpawnErrorTypes.NoActiveSession]}");
341340
yield return WaitForConditionOrTimeOut(() => !m_ServerNetworkManager.IsListening);
342341
InstantiateAndSpawn(m_ObjectsToSpawn[0], instantiateAndSpawnType);
343342
}

0 commit comments

Comments
 (0)