Skip to content

Commit 91622f0

Browse files
committed
parallelize TestRawBytesAreNotModified
1 parent 987e2b1 commit 91622f0

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

driver_test.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -3225,18 +3225,18 @@ func TestRawBytesAreNotModified(t *testing.T) {
32253225
strings.Repeat(strings.ToUpper(blob), blobSize/len(blob)),
32263226
}
32273227

3228-
runTests(t, dsn, func(dbt *DBTest) {
3229-
dbt.mustExec("CREATE TABLE test (id int, value BLOB) CHARACTER SET utf8")
3228+
runTestsParallel(t, dsn, func(dbt *DBTest, tbl string) {
3229+
dbt.mustExec("CREATE TABLE " + tbl + " (id int, value BLOB) CHARACTER SET utf8")
32303230
for i := 0; i < insertRows; i++ {
3231-
dbt.mustExec("INSERT INTO test VALUES (?, ?)", i+1, sqlBlobs[i&1])
3231+
dbt.mustExec("INSERT INTO "+tbl+" VALUES (?, ?)", i+1, sqlBlobs[i&1])
32323232
}
32333233

32343234
for i := 0; i < contextRaceIterations; i++ {
32353235
func() {
32363236
ctx, cancel := context.WithCancel(context.Background())
32373237
defer cancel()
32383238

3239-
rows, err := dbt.db.QueryContext(ctx, `SELECT id, value FROM test`)
3239+
rows, err := dbt.db.QueryContext(ctx, `SELECT id, value FROM `+tbl)
32403240
if err != nil {
32413241
dbt.Fatal(err)
32423242
}

0 commit comments

Comments
 (0)