@@ -91,6 +91,22 @@ func getConnectionString(ip, port string, options ...string) string {
91
91
}
92
92
93
93
func Test (t * testing.T ) {
94
+ t .Run ("test" , test )
95
+ t .Run ("testMigrate" , testMigrate )
96
+ t .Run ("testMultiStatement" , testMultiStatement )
97
+ t .Run ("testFilterCustomQuery" , testFilterCustomQuery )
98
+
99
+ t .Cleanup (func () {
100
+ for _ , spec := range specs {
101
+ t .Log ("Cleaning up " , spec .ImageName )
102
+ if err := spec .Cleanup (); err != nil {
103
+ t .Error ("Error removing " , spec .ImageName , "error:" , err )
104
+ }
105
+ }
106
+ })
107
+ }
108
+
109
+ func test (t * testing.T ) {
94
110
dktesting .ParallelTest (t , specs , func (t * testing.T , ci dktest.ContainerInfo ) {
95
111
createDB (t , ci )
96
112
@@ -109,7 +125,7 @@ func Test(t *testing.T) {
109
125
})
110
126
}
111
127
112
- func TestMigrate (t * testing.T ) {
128
+ func testMigrate (t * testing.T ) {
113
129
dktesting .ParallelTest (t , specs , func (t * testing.T , ci dktest.ContainerInfo ) {
114
130
createDB (t , ci )
115
131
@@ -133,7 +149,7 @@ func TestMigrate(t *testing.T) {
133
149
})
134
150
}
135
151
136
- func TestMultiStatement (t * testing.T ) {
152
+ func testMultiStatement (t * testing.T ) {
137
153
dktesting .ParallelTest (t , specs , func (t * testing.T , ci dktest.ContainerInfo ) {
138
154
createDB (t , ci )
139
155
@@ -163,7 +179,7 @@ func TestMultiStatement(t *testing.T) {
163
179
})
164
180
}
165
181
166
- func TestFilterCustomQuery (t * testing.T ) {
182
+ func testFilterCustomQuery (t * testing.T ) {
167
183
dktesting .ParallelTest (t , specs , func (t * testing.T , ci dktest.ContainerInfo ) {
168
184
createDB (t , ci )
169
185
0 commit comments