mirror of
https://github.com/opentofu/opentofu.git
synced 2025-02-25 18:45:20 -06:00
core: Fix TestContext2Apply_destroyComputed
The Provider field in ResourceState is now required, whereas before it could be omitted and have Terraform try to discover a fitting provider configuration automatically. The automatic behavior was a compatibility shim added in v0.11 to support states from prior versions without an explicit migration, but for v0.12 we will have a migration to our new state format anyway and so we will fix this up during that migration pass.
This commit is contained in:
parent
e22f1d5dce
commit
b9ed280182
@ -1194,6 +1194,7 @@ func TestContext2Apply_destroyComputed(t *testing.T) {
|
||||
"output": "value",
|
||||
},
|
||||
},
|
||||
Provider: "provider.aws",
|
||||
},
|
||||
},
|
||||
},
|
||||
@ -1211,13 +1212,13 @@ func TestContext2Apply_destroyComputed(t *testing.T) {
|
||||
})
|
||||
|
||||
if p, diags := ctx.Plan(); diags.HasErrors() {
|
||||
t.Fatalf("diags: %s", diags.Err())
|
||||
t.Fatalf("plan errors: %s", diags.Err())
|
||||
} else {
|
||||
t.Logf(p.String())
|
||||
t.Logf("plan:\n\n%s", p.String())
|
||||
}
|
||||
|
||||
if _, diags := ctx.Apply(); diags.HasErrors() {
|
||||
t.Fatalf("diags: %s", diags.Err())
|
||||
t.Fatalf("apply errors: %s", diags.Err())
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user