Added error check

This commit is contained in:
= 2017-04-19 14:22:35 -06:00
parent 6bc3610c09
commit 1608f5544f
1 changed files with 4 additions and 1 deletions

View File

@ -367,7 +367,10 @@ func testProviderFactories(c TestCase) (map[string]terraform.ResourceProviderFac
for k, pf := range ctxProviders {
// we can ignore any errors here, if we don't have a provider to reset
// the error will be handled later
p, _ := pf()
p, err := pf()
if err != nil {
return nil, err
}
if p, ok := p.(TestProvider); ok {
err := p.TestReset()
if err != nil {