tests updates
- commit
- 37f6e11c4182f435fcae32d89ab759f2b687311c
- parent
- 6050d42ba76ea2c513ca781109acdfa0c2d9776f
- parent
- 17e65b96ecb6fb4c4f6b85a8f795ead1582f0ce3
- author
- FelineStateMachine <dami.etoile@gmail.com>
| M | architecture_test.go | 17 | ----------------- |
| M | nurikabe/ | 4 | ++-- |
| M | store/ | 2 | +- |
| M | ui/ | 2 | +- |
@@ -70,23 +70,6 @@ func TestStoreCreateGameDoesNotUseNameDerivedRunMetadata(t *testing.T) {
7070 })7171 }7272 73-func TestPDFExportPackageDoesNotContainMarkdownParseEntrypoints(t *testing.T) {74- assertFilesDoNotContain(t, "pdfexport", []string{75- "func ParseMarkdown(",76- "func ParseFile(",77- "func ParseFiles(",78- "func lookupMarkdownBodyParser(",79- })80-}81-82-func TestGamePackageDoesNotExposeLegacyPrintFacade(t *testing.T) {83- if _, err := os.Stat(filepath.Join("game", "print_adapter.go")); err == nil {84- t.Fatal("game/print_adapter.go should not exist")85- } else if !os.IsNotExist(err) {86- t.Fatalf("stat game/print_adapter.go: %v", err)87- }88-}89-9073 func assertPackageDoesNotImport(t *testing.T, dir string, forbidden []string) {9174 t.Helper()9275 @@ -68,13 +68,13 @@ func TestGridStringAndParse(t *testing.T) {
6868 }6969 }7070 71-func TestParseGridLegacyRequiredLand(t *testing.T) {71+func TestParseGridMapsRequiredLandMarkerToIsland(t *testing.T) {7272 g, err := parseGrid("?!\n~o", 2, 2)7373 if err != nil {7474 t.Fatalf("parseGrid error: %v", err)7575 }7676 if g[0][1] != islandCell {77- t.Fatalf("legacy required-land marker should load as island, got %q", rune(g[0][1]))77+ t.Fatalf("required-land marker should load as island, got %q", rune(g[0][1]))7878 }7979 }8080 @@ -100,7 +100,7 @@ func TestOpen(t *testing.T) {
100100 }101101 })102102 103- t.Run("upgrades legacy databases and backfills metadata", func(t *testing.T) {103+ t.Run("upgrades databases missing run metadata and backfills it", func(t *testing.T) {104104 dbPath := filepath.Join(t.TempDir(), "legacy.db")105105 106106 raw, err := sql.Open("sqlite", dbPath)@@ -44,7 +44,7 @@ func TestMenuItemActionID(t *testing.T) {
4444 }4545 })4646 47- t.Run("falls back to title for legacy callers", func(t *testing.T) {47+ t.Run("falls back to title when action is unset", func(t *testing.T) {4848 item := MenuItem{ItemTitle: "Generate"}4949 if got := item.ActionID(); got != "Generate" {5050 t.Fatalf("ActionID() = %q, want %q", got, "Generate")