From 673af97bcd7d5c7f6ebfc4b97dca4c8822875055 Mon Sep 17 00:00:00 2001 From: Andi Li Date: Fri, 28 Aug 2020 13:44:42 -0400 Subject: [PATCH] Fix testpattern check --- test/e2e/storage/testsuites/snapshottable.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/e2e/storage/testsuites/snapshottable.go b/test/e2e/storage/testsuites/snapshottable.go index 3323a05997c..e5dc3a63848 100644 --- a/test/e2e/storage/testsuites/snapshottable.go +++ b/test/e2e/storage/testsuites/snapshottable.go @@ -359,7 +359,7 @@ type SnapshotResource struct { // different test pattern snapshot provisioning and deletion policy func CreateSnapshotResource(sDriver SnapshottableTestDriver, config *PerTestConfig, pattern testpatterns.TestPattern, pvcName string, pvcNamespace string) *SnapshotResource { var err error - if pattern.SnapshotType != testpatterns.DynamicCreatedSnapshot || pattern.SnapshotType != testpatterns.PreprovisionedCreatedSnapshot { + if pattern.SnapshotType != testpatterns.DynamicCreatedSnapshot && pattern.SnapshotType != testpatterns.PreprovisionedCreatedSnapshot { err = fmt.Errorf("SnapshotType must be set to either DynamicCreatedSnapshot or PreprovisionedCreatedSnapshot") framework.ExpectNoError(err) }