Add Unity UI Toolkit projection capture evidence
This commit is contained in:
parent
7e18a3e067
commit
08da3eddd2
13 changed files with 686 additions and 8 deletions
|
|
@ -216,6 +216,11 @@ if ($LASTEXITCODE -ne 0) {
|
|||
throw "EveUnity capture contract smoke failed with exit code $LASTEXITCODE"
|
||||
}
|
||||
|
||||
& (Join-Path $projectRoot "scripts\run-eveunity-uitoolkit-capture-smoke.ps1")
|
||||
if ($LASTEXITCODE -ne 0) {
|
||||
throw "EveUnity UI Toolkit capture smoke failed with exit code $LASTEXITCODE"
|
||||
}
|
||||
|
||||
& (Join-Path $projectRoot "scripts\run-aetheria-unity-package-smoke.ps1")
|
||||
if ($LASTEXITCODE -ne 0) {
|
||||
throw "Aetheria Unity package smoke failed with exit code $LASTEXITCODE"
|
||||
|
|
|
|||
76
scripts/run-eveunity-uitoolkit-capture-smoke.ps1
Normal file
76
scripts/run-eveunity-uitoolkit-capture-smoke.ps1
Normal file
|
|
@ -0,0 +1,76 @@
|
|||
param(
|
||||
[string] $CapabilityManifestPath = "packages\org.gamecult.eve.unity-uitoolkit\eve-runtime-capability.json",
|
||||
[string] $AdvertisementPath = "web\fixtures\aetheria.provider-advertisement.json",
|
||||
[string] $SurfacePath = "web\fixtures\aetheria-world-surface.json",
|
||||
[string] $OutputPath = "artifacts\eveunity-uitoolkit-capture\latest\unity-uitoolkit-projection.json",
|
||||
[string] $RequestOutputPath = "artifacts\eveunity-uitoolkit-capture\latest\capture-request.json",
|
||||
[string] $Stamp = "latest"
|
||||
)
|
||||
|
||||
$ErrorActionPreference = "Stop"
|
||||
|
||||
$projectRoot = Split-Path -Parent $PSScriptRoot
|
||||
function Resolve-RepoPath([string] $candidate) {
|
||||
if ([System.IO.Path]::IsPathRooted($candidate)) {
|
||||
return $candidate
|
||||
}
|
||||
return Join-Path $projectRoot $candidate
|
||||
}
|
||||
|
||||
$absoluteCapabilityPath = Resolve-RepoPath $CapabilityManifestPath
|
||||
$absoluteAdvertisementPath = Resolve-RepoPath $AdvertisementPath
|
||||
$absoluteSurfacePath = Resolve-RepoPath $SurfacePath
|
||||
$absoluteOutputPath = Resolve-RepoPath $OutputPath
|
||||
$absoluteRequestOutputPath = Resolve-RepoPath $RequestOutputPath
|
||||
|
||||
foreach ($path in @($absoluteCapabilityPath, $absoluteAdvertisementPath, $absoluteSurfacePath)) {
|
||||
if (-not (Test-Path -LiteralPath $path)) {
|
||||
throw "EveUnity UI Toolkit capture input not found: $path"
|
||||
}
|
||||
}
|
||||
|
||||
node --test (Join-Path $projectRoot "tools\eveunity\eveunity-uitoolkit-capture-artifact.test.mjs")
|
||||
if ($LASTEXITCODE -ne 0) {
|
||||
throw "EveUnity UI Toolkit capture artifact tests failed with exit code $LASTEXITCODE"
|
||||
}
|
||||
|
||||
node (Join-Path $projectRoot "tools\eveunity\eveunity-uitoolkit-capture-artifact.mjs") `
|
||||
--capability $absoluteCapabilityPath `
|
||||
--advertisement $absoluteAdvertisementPath `
|
||||
--surface $absoluteSurfacePath `
|
||||
--output $absoluteOutputPath `
|
||||
--request-output $absoluteRequestOutputPath `
|
||||
--stamp $Stamp
|
||||
if ($LASTEXITCODE -ne 0) {
|
||||
throw "EveUnity UI Toolkit capture artifact builder failed with exit code $LASTEXITCODE"
|
||||
}
|
||||
|
||||
foreach ($path in @($absoluteOutputPath, $absoluteRequestOutputPath)) {
|
||||
if (-not (Test-Path -LiteralPath $path)) {
|
||||
throw "EveUnity UI Toolkit capture artifact output missing: $path"
|
||||
}
|
||||
}
|
||||
|
||||
$projection = Get-Content -LiteralPath $absoluteOutputPath -Raw | ConvertFrom-Json
|
||||
foreach ($expectation in @(
|
||||
@{ field = "schema"; value = "gamecult.eve.unity_uitoolkit_projection.v1" },
|
||||
@{ field = "runtimeId"; value = "unity-uitoolkit" },
|
||||
@{ field = "providerId"; value = "aetheria" },
|
||||
@{ field = "surfaceId"; value = "aetheria.daemon.game" },
|
||||
@{ field = "commandBoundary"; value = "aetheria.daemon.commands" },
|
||||
@{ field = "receiptSchema"; value = "aetheria.eve_command_acceptance_status.v1" },
|
||||
@{ field = "artifactKind"; value = "json-projection" },
|
||||
@{ field = "captureKind"; value = "unity-uitoolkit-projection-json" }
|
||||
)) {
|
||||
if ($projection.($expectation.field) -ne $expectation.value) {
|
||||
throw "EveUnity UI Toolkit projection $($expectation.field) expected $($expectation.value) got $($projection.($expectation.field))"
|
||||
}
|
||||
}
|
||||
if (-not $projection.root.id) {
|
||||
throw "EveUnity UI Toolkit projection capture must contain a root UI node"
|
||||
}
|
||||
if (-not (@($projection.root.classNames) -contains "eve-component")) {
|
||||
throw "EveUnity UI Toolkit projection capture root missing eve-component class"
|
||||
}
|
||||
|
||||
Write-Host "EveUnity UI Toolkit capture smoke passed: $absoluteOutputPath"
|
||||
|
|
@ -20,6 +20,7 @@ try {
|
|||
-OutputPath "artifacts\web-reference-layout-probe\latest\sai-vn.json" `
|
||||
-Port 8893 `
|
||||
-SkipBuild
|
||||
& (Join-Path $PSScriptRoot "run-eveunity-uitoolkit-capture-smoke.ps1")
|
||||
& (Join-Path $PSScriptRoot "run-evetui-capture-smoke.ps1")
|
||||
node .\tools\parity\run-parity.mjs
|
||||
& (Join-Path $PSScriptRoot "run-eveconformance-handoff-smoke.ps1")
|
||||
|
|
|
|||
|
|
@ -46,6 +46,7 @@ node $consumerScript $consumerExport `
|
|||
--expect-schema gamecult.eve.runtime_lifecycle.v1 `
|
||||
--expect-schema gamecult.eve.runtime_split_handoff.v1 `
|
||||
--expect-schema gamecult.eve.electron_shell_projection.v1 `
|
||||
--expect-schema gamecult.eve.unity_uitoolkit_projection.v1 `
|
||||
--expect-schema gamecult.eve.unity_scene_projection.v1 `
|
||||
--expect-schema gamecult.eve.tui_grid.v1 `
|
||||
--expect-schema gamecult.eve.web_layout_probe.v1 `
|
||||
|
|
@ -132,7 +133,8 @@ node $consumerScript $consumerExport `
|
|||
--expect-runtime-capture-status windows-flutter:golden `
|
||||
--expect-runtime-capture-status linux-flutter:ssh-golden `
|
||||
--expect-runtime-capture-status android-flutter:adb-png `
|
||||
--expect-runtime-capture-status unity-uitoolkit:semantic `
|
||||
--expect-runtime-capture-status unity-uitoolkit:json-projection `
|
||||
--expect-runtime-capture-artifact unity-uitoolkit:json-projection:gamecult.eve.unity_uitoolkit_projection.v1:aetheria:aetheria.daemon.game `
|
||||
--expect-runtime-capture-status unity-scene:json-projection `
|
||||
--expect-runtime-capture-artifact unity-scene:json-projection:gamecult.eve.unity_scene_projection.v1:aetheria:aetheria.daemon.game `
|
||||
--expect-runtime-capture-status electron-shell:json-projection `
|
||||
|
|
|
|||
Loading…
Reference in a new issue