Let Rebuild the Game compile the game's code for this processor's level, and updates keep the compiled level.

make_game.py --rebuild keeps the level the objects were compiled for (lifted_level), so an update compiles only what
changed; --retune compiles for this processor's level. RebuildJob passes it, ContinueUpdateJob does not.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
chrg6
2026-11-09 10:27:17 -05:00
parent cd20bdf09f
commit fa1a2250b5
3 changed files with 18 additions and 3 deletions

View File

@@ -301,6 +301,17 @@ class GameIniTest(Tmp):
self.assertTrue((self.tmp / 'nx2navi.ini').is_dir())
class RebuildArgsTest(Tmp):
"""Rebuild the Game compiles the game's code for this processor's level (--retune); an update keeps the level its
objects were compiled for, so that it compiles only what changed (tools/make_game.py lifted_level)."""
def test_retune_only_for_rebuild_the_game(self):
self.assertIn('--retune', build.rebuild_args(self.layout, 'G:/game', True))
self.assertNotIn('--retune', build.rebuild_args(self.layout, 'G:/game'))
self.assertTrue(jobs.RebuildJob.retune)
self.assertFalse(jobs.ContinueUpdateJob.retune)
class SettingsTest(Tmp):
def test_roundtrip_and_reset(self):
s = settings.Settings(self.layout.settings)