MCPcopy
hub / github.com/sqlc-dev/sqlc / MySQL

Function MySQL

internal/sqltest/mysql.go:15–19  ·  view source on GitHub ↗
(t *testing.T, migrations []string)

Source from the content-addressed store, hash-verified

13)
14
15func MySQL(t *testing.T, migrations []string) (*sql.DB, func()) {
16 // For each test, pick a new database name at random.
17 name := "sqltest_mysql_" + id()
18 return CreateMySQLDatabase(t, name, migrations)
19}
20
21func CreateMySQLDatabase(t *testing.T, name string, migrations []string) (*sql.DB, func()) {
22 t.Helper()

Callers

nothing calls this directly

Calls 2

CreateMySQLDatabaseFunction · 0.85
idFunction · 0.70

Tested by

no test coverage detected