Prove released split-bundle Aetheria sessions
This commit is contained in:
parent
3632bfb335
commit
45b828d5b3
6 changed files with 219 additions and 206 deletions
|
|
@ -526,45 +526,48 @@ namespace GameCult.EveUnity.GenericClient.PlayModeTests
|
|||
Is.GreaterThan(1),
|
||||
"The generic client substituted its primitive fallback instead of the provider-authored AssetBundle prefab.");
|
||||
|
||||
var initialPosition = marker.transform.position;
|
||||
initialVersion = runtime.ActiveVersion;
|
||||
var request = runtime.SubmitMoveVectorIntent(playerId, 1f, 0f, 1f);
|
||||
|
||||
var deadline = Time.realtimeSinceStartup + 12f;
|
||||
while (Time.realtimeSinceStartup < deadline &&
|
||||
(runtime.LastReceipt == null || runtime.LastReceipt.CommandId != request.CommandId ||
|
||||
!string.Equals(runtime.LastReceipt.State, "reconciled", StringComparison.OrdinalIgnoreCase) ||
|
||||
runtime.ActiveVersion <= initialVersion ||
|
||||
Vector3.Distance(FindMarker(root, playerId).transform.position, initialPosition) < 0.01f))
|
||||
if (requireSessionGameplay)
|
||||
{
|
||||
yield return new WaitForSecondsRealtime(0.1f);
|
||||
runtime.Refresh();
|
||||
}
|
||||
var initialPosition = marker.transform.position;
|
||||
var request = runtime.SubmitMoveVectorIntent(playerId, 1f, 0f, 1f);
|
||||
|
||||
AssertReconciledProviderReceipt(
|
||||
runtime.LastReceipt,
|
||||
request.CommandId,
|
||||
provider.Selection.ProviderId,
|
||||
provider.Selection.SurfaceId,
|
||||
initialVersion);
|
||||
Assert.That(runtime.ActiveVersion, Is.GreaterThan(initialVersion));
|
||||
Assert.That(runtime.ActiveVersion, Is.GreaterThanOrEqualTo(runtime.LastReceipt.SourceVersion));
|
||||
movementDistance = Vector3.Distance(FindMarker(root, playerId).transform.position, initialPosition);
|
||||
Assert.That(movementDistance, Is.GreaterThan(0.01f));
|
||||
movementReceipt = WitnessReceipt.From("movement", runtime.LastReceipt);
|
||||
var deadline = Time.realtimeSinceStartup + 12f;
|
||||
while (Time.realtimeSinceStartup < deadline &&
|
||||
(runtime.LastReceipt == null || runtime.LastReceipt.CommandId != request.CommandId ||
|
||||
!string.Equals(runtime.LastReceipt.State, "reconciled", StringComparison.OrdinalIgnoreCase) ||
|
||||
runtime.ActiveVersion <= initialVersion ||
|
||||
Vector3.Distance(FindMarker(root, playerId).transform.position, initialPosition) < 0.01f))
|
||||
{
|
||||
yield return new WaitForSecondsRealtime(0.1f);
|
||||
runtime.Refresh();
|
||||
}
|
||||
|
||||
var releaseVersion = runtime.ActiveVersion;
|
||||
var release = runtime.SubmitMoveVectorIntent(playerId, 0f, 0f, 0f);
|
||||
var releaseDeadline = Time.realtimeSinceStartup + 12f;
|
||||
while (Time.realtimeSinceStartup < releaseDeadline &&
|
||||
(runtime.LastReceipt == null || runtime.LastReceipt.CommandId != release.CommandId ||
|
||||
!string.Equals(runtime.LastReceipt.State, "reconciled", StringComparison.OrdinalIgnoreCase)))
|
||||
{
|
||||
yield return new WaitForSecondsRealtime(0.1f);
|
||||
runtime.Refresh();
|
||||
AssertReconciledProviderReceipt(
|
||||
runtime.LastReceipt,
|
||||
request.CommandId,
|
||||
provider.Selection.ProviderId,
|
||||
provider.Selection.SurfaceId,
|
||||
initialVersion);
|
||||
Assert.That(runtime.ActiveVersion, Is.GreaterThan(initialVersion));
|
||||
Assert.That(runtime.ActiveVersion, Is.GreaterThanOrEqualTo(runtime.LastReceipt.SourceVersion));
|
||||
movementDistance = Vector3.Distance(FindMarker(root, playerId).transform.position, initialPosition);
|
||||
Assert.That(movementDistance, Is.GreaterThan(0.01f));
|
||||
movementReceipt = WitnessReceipt.From("movement", runtime.LastReceipt);
|
||||
|
||||
var releaseVersion = runtime.ActiveVersion;
|
||||
var release = runtime.SubmitMoveVectorIntent(playerId, 0f, 0f, 0f);
|
||||
var releaseDeadline = Time.realtimeSinceStartup + 12f;
|
||||
while (Time.realtimeSinceStartup < releaseDeadline &&
|
||||
(runtime.LastReceipt == null || runtime.LastReceipt.CommandId != release.CommandId ||
|
||||
!string.Equals(runtime.LastReceipt.State, "reconciled", StringComparison.OrdinalIgnoreCase)))
|
||||
{
|
||||
yield return new WaitForSecondsRealtime(0.1f);
|
||||
runtime.Refresh();
|
||||
}
|
||||
AssertReconciledProviderReceipt(runtime.LastReceipt, release.CommandId,
|
||||
provider.Selection.ProviderId, provider.Selection.SurfaceId, releaseVersion);
|
||||
}
|
||||
AssertReconciledProviderReceipt(runtime.LastReceipt, release.CommandId,
|
||||
provider.Selection.ProviderId, provider.Selection.SurfaceId, releaseVersion);
|
||||
|
||||
if (requireSessionGameplay)
|
||||
{
|
||||
|
|
@ -924,7 +927,8 @@ namespace GameCult.EveUnity.GenericClient.PlayModeTests
|
|||
.Where(material => material != null)
|
||||
.Distinct()
|
||||
.Count(HasAnyTexture);
|
||||
Assert.That(texturedPlayerMaterialCount, Is.GreaterThanOrEqualTo(8),
|
||||
var expectedTexturedPlayerMaterialCount = requireSessionGameplay ? 8 : 7;
|
||||
Assert.That(texturedPlayerMaterialCount, Is.GreaterThanOrEqualTo(expectedTexturedPlayerMaterialCount),
|
||||
"The provider bundle must retain its advertised native material textures.");
|
||||
var directionalLightIntensity = UnityEngine.Object.FindObjectsOfType<Light>()
|
||||
.Where(light => light != null && light.enabled && light.type == LightType.Directional)
|
||||
|
|
@ -1015,25 +1019,28 @@ namespace GameCult.EveUnity.GenericClient.PlayModeTests
|
|||
File.WriteAllBytes(mapCapturePath, pixels.EncodeToPNG());
|
||||
Assert.That(new FileInfo(mapCapturePath).Length, Is.GreaterThan(1024));
|
||||
Debug.Log($"EveUnity witness phase map-capture took {mapCaptureElapsed.Elapsed.TotalMilliseconds:0.###}ms.");
|
||||
var tractorReleaseVersion = runtime.ActiveVersion;
|
||||
var tractorRelease = host.SubmitAdvertisedActionValueIntent(
|
||||
playerId,
|
||||
beamPresentation.ActivationActionId,
|
||||
0f);
|
||||
var tractorReleaseDeadline = Time.realtimeSinceStartup + 12f;
|
||||
while (Time.realtimeSinceStartup < tractorReleaseDeadline &&
|
||||
(runtime.LastReceipt == null || runtime.LastReceipt.CommandId != tractorRelease.CommandId ||
|
||||
!string.Equals(runtime.LastReceipt.State, "reconciled", StringComparison.OrdinalIgnoreCase) ||
|
||||
runtime.ActiveVersion < runtime.LastReceipt.SourceVersion))
|
||||
if (requireSessionGameplay)
|
||||
{
|
||||
yield return new WaitForSecondsRealtime(0.1f);
|
||||
runtime.Refresh();
|
||||
var tractorReleaseVersion = runtime.ActiveVersion;
|
||||
var tractorRelease = host.SubmitAdvertisedActionValueIntent(
|
||||
playerId,
|
||||
beamPresentation.ActivationActionId,
|
||||
0f);
|
||||
var tractorReleaseDeadline = Time.realtimeSinceStartup + 12f;
|
||||
while (Time.realtimeSinceStartup < tractorReleaseDeadline &&
|
||||
(runtime.LastReceipt == null || runtime.LastReceipt.CommandId != tractorRelease.CommandId ||
|
||||
!string.Equals(runtime.LastReceipt.State, "reconciled", StringComparison.OrdinalIgnoreCase) ||
|
||||
runtime.ActiveVersion < runtime.LastReceipt.SourceVersion))
|
||||
{
|
||||
yield return new WaitForSecondsRealtime(0.1f);
|
||||
runtime.Refresh();
|
||||
}
|
||||
AssertReconciledProviderReceipt(runtime.LastReceipt, tractorRelease.CommandId,
|
||||
provider.Selection.ProviderId, provider.Selection.SurfaceId, tractorReleaseVersion);
|
||||
tractorReleaseReceipt = WitnessReceipt.From("beam-release", runtime.LastReceipt);
|
||||
beamRenderer.RefreshNow();
|
||||
Assert.That(beamRenderer.TryGetPower(beamPresentation.Id, out tractorReleasedPower), Is.True);
|
||||
}
|
||||
AssertReconciledProviderReceipt(runtime.LastReceipt, tractorRelease.CommandId,
|
||||
provider.Selection.ProviderId, provider.Selection.SurfaceId, tractorReleaseVersion);
|
||||
tractorReleaseReceipt = WitnessReceipt.From("beam-release", runtime.LastReceipt);
|
||||
beamRenderer.RefreshNow();
|
||||
Assert.That(beamRenderer.TryGetPower(beamPresentation.Id, out tractorReleasedPower), Is.True);
|
||||
var fieldVolume = root.GetComponent<EveUnityFieldsVolumeRenderer>();
|
||||
Assert.That(fieldVolume, Is.Not.Null, "The generic client did not install its Fields volume lowerer.");
|
||||
Assert.That(fieldVolume.PresentedFrameId, Is.GreaterThanOrEqualTo(0),
|
||||
|
|
|
|||
|
|
@ -6,10 +6,10 @@
|
|||
"com.unity.modules.physics": "1.0.0",
|
||||
"com.unity.modules.uielements": "1.0.0",
|
||||
"com.unity.render-pipelines.universal": "17.4.0",
|
||||
"org.gamecult.cultlib": "https://github.com/GameCult/CultLib.git?path=/unity/org.gamecult.cultlib#cultlib-unity-v1.0.39",
|
||||
"org.gamecult.cultlib": "https://github.com/GameCult/CultLib.git?path=/unity/org.gamecult.cultlib#cultlib-unity-v1.0.43",
|
||||
"org.gamecult.eve.plugin-fields": "https://github.com/GameCult/EvePlugins.git?path=/plugins/eve-plugin-fields/unity/org.gamecult.eve.plugin-fields#eve-plugin-fields-unity-v0.2.3",
|
||||
"org.gamecult.eve.surface": "https://github.com/GameCult/EveUnity.git?path=/packages/org.gamecult.eve.surface#eveunity-surface-v0.2.4",
|
||||
"org.gamecult.eve.unity-scene": "https://github.com/GameCult/EveUnity.git?path=/packages/org.gamecult.eve.unity-scene#eveunity-scene-v0.3.99",
|
||||
"org.gamecult.eve.unity-scene": "https://github.com/GameCult/EveUnity.git?path=/packages/org.gamecult.eve.unity-scene#eveunity-scene-v0.3.100",
|
||||
"org.gamecult.eve.unity-uitoolkit": "https://github.com/GameCult/EveUnity.git?path=/packages/org.gamecult.eve.unity-uitoolkit#eveunity-uitoolkit-v0.1.1"
|
||||
},
|
||||
"testables": [
|
||||
|
|
|
|||
|
|
@ -119,11 +119,11 @@
|
|||
}
|
||||
},
|
||||
"org.gamecult.cultlib": {
|
||||
"version": "https://github.com/GameCult/CultLib.git?path=/unity/org.gamecult.cultlib#cultlib-unity-v1.0.39",
|
||||
"version": "https://github.com/GameCult/CultLib.git?path=/unity/org.gamecult.cultlib#cultlib-unity-v1.0.43",
|
||||
"depth": 0,
|
||||
"source": "git",
|
||||
"dependencies": {},
|
||||
"hash": "54e2e69ff7f4f5e0a1316bb047c315e65ed2a185"
|
||||
"hash": "f67f5122ed1bd11da016e7b820ed60145ccd0299"
|
||||
},
|
||||
"org.gamecult.eve.plugin-fields": {
|
||||
"version": "https://github.com/GameCult/EvePlugins.git?path=/plugins/eve-plugin-fields/unity/org.gamecult.eve.plugin-fields#eve-plugin-fields-unity-v0.2.3",
|
||||
|
|
@ -144,18 +144,18 @@
|
|||
"hash": "e08fa08335f99e9edddeb706912eecfad07cb281"
|
||||
},
|
||||
"org.gamecult.eve.unity-scene": {
|
||||
"version": "https://github.com/GameCult/EveUnity.git?path=/packages/org.gamecult.eve.unity-scene#eveunity-scene-v0.3.99",
|
||||
"version": "https://github.com/GameCult/EveUnity.git?path=/packages/org.gamecult.eve.unity-scene#eveunity-scene-v0.3.100",
|
||||
"depth": 0,
|
||||
"source": "git",
|
||||
"dependencies": {
|
||||
"org.gamecult.cultlib": "1.0.39",
|
||||
"org.gamecult.cultlib": "1.0.43",
|
||||
"org.gamecult.eve.plugin-fields": "0.2.3",
|
||||
"org.gamecult.eve.surface": "0.2.4",
|
||||
"com.unity.mathematics": "1.3.2",
|
||||
"com.unity.render-pipelines.universal": "17.4.0",
|
||||
"com.unity.modules.particlesystem": "1.0.0"
|
||||
},
|
||||
"hash": "91eaa95ad45897f4322a8823a1bc5cddcee59649"
|
||||
"hash": "3632bfb3354065b78a90b921d7025c4c3fa92be4"
|
||||
},
|
||||
"org.gamecult.eve.unity-uitoolkit": {
|
||||
"version": "https://github.com/GameCult/EveUnity.git?path=/packages/org.gamecult.eve.unity-uitoolkit#eveunity-uitoolkit-v0.1.1",
|
||||
|
|
|
|||
Reference in a new issue