unified-storage: refactor Sql backend and sqlkv compat tests (#115849)

* move sql and sqlkv backends compatibility tests

* refactor compatibility tests

* run storage backend tests with and without rvmanager

* fix

* fix

* fmt

* fix

* address feedback

* fmt
This commit is contained in:
Will Assis
2026-01-08 15:06:44 -05:00
committed by GitHub
parent a79cda3328
commit f669bc4448
5 changed files with 319 additions and 296 deletions
@@ -107,16 +107,20 @@ func TestIntegrationSQLStorageAndSQLKVCompatibilityTests(t *testing.T) {
testutil.SkipIntegrationTestInShortMode(t)
t.Cleanup(db.CleanupTestDB)
newKvBackend := func(ctx context.Context) (resource.StorageBackend, sqldb.DB) {
return unitest.NewTestSqlKvBackend(t, ctx, true)
}
t.Run("IsHA (polling notifier)", func(t *testing.T) {
unitest.RunSQLStorageBackendCompatibilityTest(t, func(ctx context.Context) (resource.StorageBackend, sqldb.DB) {
return newTestBackend(t, true, 0)
}, nil)
}, newKvBackend, nil)
})
t.Run("NotHA (in process notifier)", func(t *testing.T) {
unitest.RunSQLStorageBackendCompatibilityTest(t, func(ctx context.Context) (resource.StorageBackend, sqldb.DB) {
return newTestBackend(t, false, 0)
}, nil)
}, newKvBackend, nil)
})
}