write provider to state for refresh nodes
and update the test state strings
This commit is contained in:
parent
c2f3522f7d
commit
3977fe8b2d
|
@ -3527,28 +3527,34 @@ STATE:
|
|||
|
||||
aws_instance.bar.0:
|
||||
ID = bar0
|
||||
provider = provider.aws
|
||||
|
||||
Dependencies:
|
||||
aws_instance.foo.*
|
||||
aws_instance.bar.1:
|
||||
ID = bar1
|
||||
provider = provider.aws
|
||||
|
||||
Dependencies:
|
||||
aws_instance.foo.*
|
||||
aws_instance.baz.0:
|
||||
ID = baz0
|
||||
provider = provider.aws
|
||||
|
||||
Dependencies:
|
||||
aws_instance.bar.*
|
||||
aws_instance.baz.1:
|
||||
ID = baz1
|
||||
provider = provider.aws
|
||||
|
||||
Dependencies:
|
||||
aws_instance.bar.*
|
||||
aws_instance.foo.0:
|
||||
ID = foo0
|
||||
provider = provider.aws
|
||||
aws_instance.foo.1:
|
||||
ID = foo1
|
||||
provider = provider.aws
|
||||
`)
|
||||
if actual != expected {
|
||||
t.Fatalf("bad:\n%s\n\nexpected\n\n%s", actual, expected)
|
||||
|
|
|
@ -416,15 +416,18 @@ root
|
|||
const testContextRefreshModuleStr = `
|
||||
aws_instance.web: (tainted)
|
||||
ID = bar
|
||||
provider = provider.aws
|
||||
|
||||
module.child:
|
||||
aws_instance.web:
|
||||
ID = new
|
||||
provider = provider.aws
|
||||
`
|
||||
|
||||
const testContextRefreshOutputStr = `
|
||||
aws_instance.web:
|
||||
ID = foo
|
||||
provider = provider.aws
|
||||
foo = bar
|
||||
|
||||
Outputs:
|
||||
|
@ -439,4 +442,5 @@ const testContextRefreshOutputPartialStr = `
|
|||
const testContextRefreshTaintedStr = `
|
||||
aws_instance.web: (tainted)
|
||||
ID = foo
|
||||
provider = provider.aws
|
||||
`
|
||||
|
|
|
@ -275,7 +275,7 @@ func (n *NodeDestroyResource) EvalTree() EvalNode {
|
|||
&EvalWriteState{
|
||||
Name: stateId,
|
||||
ResourceType: n.Addr.Type,
|
||||
Provider: rs.Provider,
|
||||
Provider: n.ResolvedProvider,
|
||||
Dependencies: rs.Dependencies,
|
||||
State: &state,
|
||||
},
|
||||
|
|
|
@ -166,7 +166,7 @@ func (n *NodeRefreshableManagedResourceInstance) evalTreeManagedResource() EvalN
|
|||
&EvalWriteState{
|
||||
Name: stateId,
|
||||
ResourceType: n.ResourceState.Type,
|
||||
Provider: n.ResourceState.Provider,
|
||||
Provider: n.ResolvedProvider,
|
||||
Dependencies: n.ResourceState.Dependencies,
|
||||
State: &state,
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue