Skip to content

Commit

Permalink
add property for test case opt out
Browse files Browse the repository at this point in the history
  • Loading branch information
kmoe committed Feb 4, 2020
1 parent 40dd0c9 commit 10a4cec
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion helper/resource/testing.go
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,11 @@ type TestCase struct {
// IDRefreshIgnore is a list of configuration keys that will be ignored.
IDRefreshName string
IDRefreshIgnore []string

// DisableBinaryDriver forces this test case to run using the legacy test
// driver, even if the binary test driver has been enabled.
// This property will be removed in version 2.0.0 of the SDK.
DisableBinaryDriver bool
}

// TestStep is a single apply sequence of a test, done within the
Expand Down Expand Up @@ -567,7 +572,7 @@ func Test(t TestT, c TestCase) {
providers[name] = p
}

if acctest.TestHelper != nil {
if acctest.TestHelper != nil && c.DisableBinaryDriver == false {
// inject providers for ImportStateVerify
RunLegacyTest(t.(*testing.T), c, providers)
return
Expand Down

0 comments on commit 10a4cec

Please sign in to comment.