Minor improvement on the organization of tests on test_adapters.go

pull/36/head
Vinícius Garcia 2023-04-04 23:08:29 -03:00
parent 94d41d437e
commit ec1f5f6151
1 changed files with 12 additions and 10 deletions

View File

@ -72,16 +72,18 @@ func RunTestsForAdapter(
connStr string,
newDBAdapter func(t *testing.T) (DBAdapter, io.Closer),
) {
t.Run(adapterName+"."+dialect.DriverName(), func(t *testing.T) {
QueryTest(t, dialect, connStr, newDBAdapter)
QueryOneTest(t, dialect, connStr, newDBAdapter)
InsertTest(t, dialect, connStr, newDBAdapter)
DeleteTest(t, dialect, connStr, newDBAdapter)
PatchTest(t, dialect, connStr, newDBAdapter)
QueryChunksTest(t, dialect, connStr, newDBAdapter)
TransactionTest(t, dialect, connStr, newDBAdapter)
ModifiersTest(t, dialect, connStr, newDBAdapter)
ScanRowsTest(t, dialect, connStr, newDBAdapter)
t.Run(adapterName, func(t *testing.T) {
t.Run(dialect.DriverName(), func(t *testing.T) {
QueryTest(t, dialect, connStr, newDBAdapter)
QueryOneTest(t, dialect, connStr, newDBAdapter)
InsertTest(t, dialect, connStr, newDBAdapter)
DeleteTest(t, dialect, connStr, newDBAdapter)
PatchTest(t, dialect, connStr, newDBAdapter)
QueryChunksTest(t, dialect, connStr, newDBAdapter)
TransactionTest(t, dialect, connStr, newDBAdapter)
ModifiersTest(t, dialect, connStr, newDBAdapter)
ScanRowsTest(t, dialect, connStr, newDBAdapter)
})
})
}