test(switch): close the silent-regression gaps the Yellow NX bug exposed

Three layers, all running without a ROM:

- nx_yellow_boot_test.lua: drives the real Yellow and Blue boot states
  (TitleState, YellowIntro + IntroMovie pre-roll for Yellow, IntroMovie
  direct for Blue, Sound.playPikaCry) against a broken-mount filesystem
  where generated art exists only under yellow|blue/, and asserts no bare
  assets/generated path ever reaches the raw love loaders.  This is the
  runtime complement to the static literal guard: data-driven manifest
  paths and formatted paths (cry_%02d.wav) are exactly what a source scan
  cannot see.  love_stub gains Image:setFilter/getFilter so IntroMovie
  constructs headless.

- CI path gate: switch-changes now also triggers on the NX runtime
  (NxAssetOverlay, Platform, GameVersion, CacheFs) and the NX engine
  suites, so src-side NX regressions rebuild the fused NRO instead of
  slipping through with green headless-only checks.

- switch-selftest runs the three NX engine suites headlessly on the
  fork-safe ubuntu runner, giving PR feedback before the self-hosted Mac
  build.  The content gate and switch-build.md docs were updated in sync.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Andrew Quenehen
2026-08-03 16:07:41 -03:00
parent 0bd3b26acc
commit 98c08e4b22
5 changed files with 382 additions and 5 deletions
+9 -1
View File
@@ -120,7 +120,7 @@ jobs:
echo "changed=true" >> "$GITHUB_OUTPUT"
exit 0
fi
if git diff --name-only "$BASE_SHA" "$HEAD_SHA" | grep -Eq '^(scripts/build_switch\.sh$|scripts/switch/|docs/switch-.*\.md$|tests/switch_ci_workflows_test\.lua$|tests/switch_transfer_docs_test\.lua$|\.github/workflows/(ci|release|switch-artifact-comment)\.yml$)'; then
if git diff --name-only "$BASE_SHA" "$HEAD_SHA" | grep -Eq '^(scripts/build_switch\.sh$|scripts/switch/|docs/switch-.*\.md$|tests/switch_ci_workflows_test\.lua$|tests/switch_transfer_docs_test\.lua$|\.github/workflows/(ci|release|switch-artifact-comment)\.yml$|src/core/(NxAssetOverlay|Platform|GameVersion)\.lua$|src/import/CacheFs\.lua$|tests/engine/(assets_version_fallback|nx_generated_guard|nx_yellow_boot|switch_diagnostics)_test\.lua$|tests/engine/platform_nx)'; then
echo "changed=true" >> "$GITHUB_OUTPUT"
else
echo "changed=false" >> "$GITHUB_OUTPUT"
@@ -143,6 +143,14 @@ jobs:
run: luajit tests/switch_ci_workflows_test.lua
- name: Switch transfer docs content gate
run: luajit tests/switch_transfer_docs_test.lua
# NX runtime regressions gate this job via switch-changes; run the NX
# engine suites here too so a PR touching them gets feedback on the
# fork-safe ubuntu runner before the self-hosted Mac build.
- name: NX engine suites (headless)
run: |
luajit tests/engine/assets_version_fallback_test.lua
luajit tests/engine/nx_generated_guard_test.lua
luajit tests/engine/nx_yellow_boot_test.lua
switch-build:
name: Switch fused build