MCPcopy
hub / github.com/go-sql-driver/mysql / configForTests

Function configForTests

driver_test.go:3361–3373  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

3359}
3360
3361func configForTests(t *testing.T) *Config {
3362 if !available {
3363 t.Skipf("MySQL server not running on %s", netAddr)
3364 }
3365
3366 mycnf := NewConfig()
3367 mycnf.User = user
3368 mycnf.Passwd = pass
3369 mycnf.Addr = addr
3370 mycnf.Net = prot
3371 mycnf.DBName = dbname
3372 return mycnf
3373}
3374
3375func TestNewConnector(t *testing.T) {
3376 mycnf := configForTests(t)

Callers 2

TestNewConnectorFunction · 0.85

Calls 1

NewConfigFunction · 0.85

Tested by

no test coverage detected