diff --git a/pkg/ccl/backupccl/backup_test.go b/pkg/ccl/backupccl/backup_test.go index a66d87f669eb..f804db11a632 100644 --- a/pkg/ccl/backupccl/backup_test.go +++ b/pkg/ccl/backupccl/backup_test.go @@ -1893,6 +1893,13 @@ func TestBackupRestoreWithConcurrentWrites(t *testing.T) { sqlDB.Exec(t, `RESTORE data.* FROM $1`, localFoo) atomic.StoreInt32(&allowErrors, 0) + // TODO(pbardea): Without this wait we see this test falke under stress. + // See #40951 for the tracking issue. + testutils.SucceedsSoon(t, func() error { + _, err := tc.Conns[0].Exec("SELECT * FROM data.bank LIMIT 1") + return err + }) + bad := sqlDB.QueryStr(t, `SELECT id, balance, payload FROM data.bank WHERE id != balance`) for _, r := range bad { t.Errorf("bad row ID %s = bal %s (payload: %q)", r[0], r[1], r[2])