PoC: replace using testing.Short in storage/unified package with integration test skip method (#107887)

* PoC: check if testing.Short is called from integration tests only.

* Rename helper function.

* Fix logic.

* Remove skipping of integration tests from non-integration tests.

* Remove skipping of integration tests from non-integration tests.

* Fix import.
This commit is contained in:
Peter Štibraný
2025-07-09 15:32:10 +00:00
committed by GitHub
parent 5108225785
commit 9d2eadcfd2
7 changed files with 21 additions and 26 deletions
-4
View File
@@ -43,10 +43,6 @@ func GenerateRandomKVPrefix() string {
// RunKVTest runs the KV test suite
func RunKVTest(t *testing.T, newKV NewKVFunc, opts *KVTestOptions) {
if testing.Short() {
t.Skip("skipping integration test")
}
if opts == nil {
opts = &KVTestOptions{}
}
@@ -24,10 +24,6 @@ type NewSearchBackendFunc func(ctx context.Context) resource.SearchBackend
// RunSearchBackendTest runs the search backend test suite
func RunSearchBackendTest(t *testing.T, newBackend NewSearchBackendFunc, opts *TestOptions) {
if testing.Short() {
t.Skip("skipping integration test")
}
if opts == nil {
opts = &TestOptions{}
}