mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
Test simplified
This commit is contained in:
parent
512f60a3ef
commit
9dbd45c9d8
@ -368,12 +368,10 @@ public void VirtualOverrideHook_HookCalledWhenSyncingChangedValue(bool intialSta
|
||||
out _, out _, out VirtualOverrideHook serverObject,
|
||||
out _, out _, out VirtualOverrideHook clientObject);
|
||||
|
||||
const int clientValue = 10;
|
||||
const int serverValue = 24;
|
||||
|
||||
// change it on server
|
||||
serverObject.value = serverValue;
|
||||
clientObject.value = clientValue;
|
||||
|
||||
// hook should change it on client
|
||||
int overrideCallCount = 0;
|
||||
@ -381,7 +379,7 @@ public void VirtualOverrideHook_HookCalledWhenSyncingChangedValue(bool intialSta
|
||||
clientObject.OverrideHookCalled += (oldValue, newValue) =>
|
||||
{
|
||||
overrideCallCount++;
|
||||
Assert.That(oldValue, Is.EqualTo(clientValue));
|
||||
Assert.That(oldValue, Is.EqualTo(0));
|
||||
Assert.That(newValue, Is.EqualTo(serverValue));
|
||||
};
|
||||
clientObject.BaseHookCalled += (oldValue, newValue) =>
|
||||
|
Loading…
Reference in New Issue
Block a user