diff options
| author | historia <[not public]> | 2026-07-07 16:46:32 -0400 |
|---|---|---|
| committer | historia <[not public]> | 2026-07-07 16:46:32 -0400 |
| commit | 726997d799edc388cd448e978d5bb0755aaa551c (patch) | |
| tree | b7aa8dc2dc9d2edcad1c0a4012a28d01d348db69 /internal/game/exit_migrate_test.go | |
| parent | ab2597b22ccdb71116992aec78080d9858358d04 (diff) | |
| download | thehouseoficarus-726997d799edc388cd448e978d5bb0755aaa551c.tar.gz | |
feat: bitpacked and base64 encoded VisitedRooms in player YAML to keep the file human readable
Diffstat (limited to 'internal/game/exit_migrate_test.go')
| -rw-r--r-- | internal/game/exit_migrate_test.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/internal/game/exit_migrate_test.go b/internal/game/exit_migrate_test.go index 05edea5..f86b85b 100644 --- a/internal/game/exit_migrate_test.go +++ b/internal/game/exit_migrate_test.go @@ -21,7 +21,7 @@ func TestRewritePlayerRoomIDsRename(t *testing.T) { 30: {Char: "Y"}, }, } - p.Stats.RoomsVisited = map[int]bool{10: true, 40: true} + p.Stats.RoomsVisited = player.NewRoomSetFrom(10, 40) idMap := map[int]int{10: 100, 20: 200} if !rewritePlayerRoomIDs(p, idMap) { @@ -53,13 +53,13 @@ func TestRewritePlayerRoomIDsRename(t *testing.T) { if _, ok := p.MapSymbols[10]; ok { t.Error("MapSymbols should not still have key 10") } - if !p.Stats.RoomsVisited[100] { + if !p.Stats.RoomsVisited.Has(100) { t.Error("RoomsVisited missing key 100") } - if !p.Stats.RoomsVisited[40] { + if !p.Stats.RoomsVisited.Has(40) { t.Error("RoomsVisited missing unchanged key 40") } - if p.Stats.RoomsVisited[10] { + if p.Stats.RoomsVisited.Has(10) { t.Error("RoomsVisited should not still have key 10") } } |
