Skip to content

Commit a354b38

Browse files
committed
fix: restore skip behavior in local database helpers
Keep t.Skip() instead of t.Fatal() in local postgres.go and mysql.go when database is unavailable. This allows tests to be skipped gracefully when neither Docker nor native installation is available. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent e0cd02f commit a354b38

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

internal/sqltest/local/mysql.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ func MySQL(t *testing.T, migrations []string) string {
4040
}
4141
dburi = u
4242
} else {
43-
t.Fatal("MYSQL_SERVER_URI is empty and neither Docker nor native installation is available")
43+
t.Skip("MYSQL_SERVER_URI is empty and neither Docker nor native installation is available")
4444
}
4545
}
4646

internal/sqltest/local/postgres.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ func postgreSQL(t *testing.T, migrations []string, rw bool) string {
5050
}
5151
dburi = u
5252
} else {
53-
t.Fatal("POSTGRESQL_SERVER_URI is empty and neither Docker nor native installation is available")
53+
t.Skip("POSTGRESQL_SERVER_URI is empty and neither Docker nor native installation is available")
5454
}
5555
}
5656

0 commit comments

Comments
 (0)