mud/tests
Jared Miller b0fb9b5e2c
Wire op_restore to QuetzalParser and filesystem
Implement V3 restore opcode:
- Add QuetzalParser.load_from_bytes() to parse save data from memory
- Wire op_restore to call filesystem.restore_game() and parse result
- Validate IFhd matches current story (release/serial/checksum)
- Restore dynamic memory, call stack, and program counter
- Branch true on success, false on failure/cancellation

Fix IFF chunk padding bug:
- Add padding byte to odd-length chunks in QuetzalWriter
- Ensures proper chunk alignment for parser compatibility

Add comprehensive tests:
- Branch false when filesystem returns None
- Branch false without zmachine reference
- Branch true on successful restore
- Verify memory state matches saved values
- Handle malformed save data gracefully
2026-02-10 10:13:45 -05:00
..
test_ansi.py Wire client capabilities into Player & terrain 2026-02-07 22:44:45 -05:00
test_caps.py Add MTTS capability parsing module with client color detection 2026-02-07 22:44:23 -05:00
test_collision_detection.py Add collision detection tests 2026-02-08 13:32:49 -05:00
test_combat_commands.py Add reload command for hot-reloading TOML content 2026-02-08 14:32:51 -05:00
test_combat_encounter.py Add 30-second idle timeout for combat encounters 2026-02-08 12:28:17 -05:00
test_combat_engine.py Fix variant defense mode and test cleanup 2026-02-08 12:28:17 -05:00
test_combat_moves.py Update tests for alias removal 2026-02-08 13:39:58 -05:00
test_commands.py Add editor mode shell integration and edit command 2026-02-07 22:59:37 -05:00
test_commands_list.py Update tests for clean command listings 2026-02-08 13:41:36 -05:00
test_content_loader.py Add TOML content loader for declarative command definitions 2026-02-07 20:27:29 -05:00
test_editor.py Fix editor search/replace parsing, dirty flag, and cursor tracking 2026-02-07 23:06:47 -05:00
test_editor_integration.py Wire edit command to open combat TOML files 2026-02-08 12:44:56 -05:00
test_effects.py Add fly command with cloud trail effects 2026-02-07 14:48:42 -05:00
test_entity.py Add defense commitment lock and defense-everywhere support 2026-02-08 12:28:17 -05:00
test_fly.py Stagger cloud trail dissolution so tiles fade one at a time 2026-02-07 14:48:42 -05:00
test_help_command.py Implement standalone help command 2026-02-08 13:33:46 -05:00
test_highlight.py Wire client capabilities into Player & terrain 2026-02-07 22:44:45 -05:00
test_if_mode.py Fix line-too-long lint errors in IF mode tests 2026-02-09 16:10:29 -05:00
test_if_session.py Strip dfrotz prompt even without preceding newline 2026-02-09 17:55:14 -05:00
test_if_spectator.py Add broadcast_to_spectators helper 2026-02-09 16:24:48 -05:00
test_import.py Add first generation 2026-02-07 09:45:48 -05:00
test_login_flow.py Add login and registration flow with server integration 2026-02-07 21:42:12 -05:00
test_mob_ai.py Add spawn command and wire mobs into server 2026-02-09 11:54:29 -05:00
test_mobs.py Add spawn command and wire mobs into server 2026-02-09 11:54:29 -05:00
test_persistence.py Add save on logout and disconnect 2026-02-07 21:42:16 -05:00
test_play_command.py Wire restore into play command 2026-02-09 16:39:15 -05:00
test_player_caps.py Wire client capabilities into Player & terrain 2026-02-07 22:44:45 -05:00
test_prefix_matching.py Add test for alias exact match over prefix 2026-02-08 13:48:32 -05:00
test_quetzal_stks.py Fix off-by-one in QuetzalParser return_pc parsing 2026-02-10 10:13:33 -05:00
test_quetzal_writer.py Wire op_restore to QuetzalParser and filesystem 2026-02-10 10:13:45 -05:00
test_reload.py Add reload command for hot-reloading TOML content 2026-02-08 14:32:51 -05:00
test_rest.py Add rest command for stamina recovery 2026-02-08 22:16:47 -05:00
test_server.py Add login and registration flow with server integration 2026-02-07 21:42:12 -05:00
test_spawn_command.py Add spawn command and wire mobs into server 2026-02-09 11:54:29 -05:00
test_store.py Add store module with SQLite account persistence 2026-02-07 21:42:07 -05:00
test_terrain.py Add world cache to speedup startup 2026-02-07 15:00:07 -05:00
test_variant_prefix.py Fix prefix matching for combat move variants 2026-02-08 14:41:40 -05:00
test_zmachine_opcodes.py Wire op_restore to QuetzalParser and filesystem 2026-02-10 10:13:45 -05:00