From d95c68d8913d3ac434d86a681d215bd0da230b44 Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Fri, 24 Apr 2026 13:12:35 +0200 Subject: tests: add jetpac.nes to the end-to-end tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Miquel Sabaté Solà --- .gitmodules | 3 +++ scripts/test-e2e.sh | 20 ++++++++++++++++++++ tests/jetpac.nes | 1 + 3 files changed, 24 insertions(+) create mode 160000 tests/jetpac.nes diff --git a/.gitmodules b/.gitmodules index 7dd6a24..5bfc7b6 100644 --- a/.gitmodules +++ b/.gitmodules @@ -4,3 +4,6 @@ [submodule "tests/code.nes"] path = tests/code.nes url = git@github.com:mssola/code.nes +[submodule "tests/jetpac.nes"] + path = tests/jetpac.nes + url = https://github.com/mssola/jetpac.nes diff --git a/scripts/test-e2e.sh b/scripts/test-e2e.sh index ddb7b0a..b25b50b 100755 --- a/scripts/test-e2e.sh +++ b/scripts/test-e2e.sh @@ -191,6 +191,26 @@ echo "test: aoc2023.nes => 4.nes" $AS65 --no-errors -b ./target/debug/nasm -C tests/cfg/nrom65.cfg -o /dev/null tests/aoc2023.nes/src/4.s exit_code=$((exit_code + $?)) +## +# jetpac.nes + +echo "test: jetpac.nes" + +# Re-generate the config/generated.s file, which is usually built on a 'make +# build-*' target. +rm -f tests/jetpac.nes/config/generated.s +echo "HZ = 60" >> tests/jetpac.nes/config/generated.s +echo "LEVEL = 0" >> tests/jetpac.nes/config/generated.s + +# NOTE: we use '--stats' as otherwise the 'segments.txt' file would be removed +# from the jetpac.nes repository, and the submodule would then be marked with +# "-dirty". +$AS65 --no-errors --strict --stats -b ./target/debug/nasm -C tests/jetpac.nes/config/nrom.cfg -o /dev/null tests/jetpac.nes/src/jetpac.s 1>/dev/null + +# Remove the generated.s file to avoid git from thinking we have modified the +# project in any meaningful way. +rm -f tests/jetpac.nes/config/generated.s + ## # Done! diff --git a/tests/jetpac.nes b/tests/jetpac.nes new file mode 160000 index 0000000..db2468e --- /dev/null +++ b/tests/jetpac.nes @@ -0,0 +1 @@ +Subproject commit db2468e22b0eaaa78e68193839b0ef928384c24a -- cgit v1.2.3