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 {
case "":
supported = true
case testpatterns.DynamicCreatedSnapshot:
if d.SnapshotClass.FromName || d.SnapshotClass.FromFile != "" || d.SnapshotClass.FromExistingClassName != "" {
supported = true
}
case testpatterns.PreprovisionedCreatedSnapshot:
case testpatterns.DynamicCreatedSnapshot, testpatterns.PreprovisionedCreatedSnapshot:
if d.SnapshotClass.FromName || d.SnapshotClass.FromFile != "" || d.SnapshotClass.FromExistingClassName != "" {
supported = true
}