Combine switch case into one case

This commit is contained in:
Andi Li 2020-08-27 22:32:27 -04:00
parent 5b4dffb6b7
commit d915463451

View File

@ -251,11 +251,7 @@ func (d *driverDefinition) SkipUnsupportedTest(pattern testpatterns.TestPattern)
switch pattern.SnapshotType { switch pattern.SnapshotType {
case "": case "":
supported = true supported = true
case testpatterns.DynamicCreatedSnapshot: case testpatterns.DynamicCreatedSnapshot, testpatterns.PreprovisionedCreatedSnapshot:
if d.SnapshotClass.FromName || d.SnapshotClass.FromFile != "" || d.SnapshotClass.FromExistingClassName != "" {
supported = true
}
case testpatterns.PreprovisionedCreatedSnapshot:
if d.SnapshotClass.FromName || d.SnapshotClass.FromFile != "" || d.SnapshotClass.FromExistingClassName != "" { if d.SnapshotClass.FromName || d.SnapshotClass.FromFile != "" || d.SnapshotClass.FromExistingClassName != "" {
supported = true supported = true
} }