terraform: another test
This commit is contained in:
parent
a616c362de
commit
5ba52ceac4
|
@ -98,11 +98,10 @@ func TestContext2Refresh_delete(t *testing.T) {
|
|||
}
|
||||
}
|
||||
|
||||
/*
|
||||
func TestContextRefresh_ignoreUncreated(t *testing.T) {
|
||||
func TestContext2Refresh_ignoreUncreated(t *testing.T) {
|
||||
p := testProvider("aws")
|
||||
m := testModule(t, "refresh-basic")
|
||||
ctx := testContext(t, &ContextOpts{
|
||||
ctx := testContext2(t, &ContextOpts{
|
||||
Module: m,
|
||||
Providers: map[string]ResourceProviderFactory{
|
||||
"aws": testProviderFuncFixed(p),
|
||||
|
@ -124,6 +123,7 @@ func TestContextRefresh_ignoreUncreated(t *testing.T) {
|
|||
}
|
||||
}
|
||||
|
||||
/*
|
||||
func TestContextRefresh_hook(t *testing.T) {
|
||||
h := new(MockHook)
|
||||
p := testProvider("aws")
|
||||
|
|
|
@ -22,6 +22,11 @@ func (n *EvalRefresh) Eval(
|
|||
state = args[1].(*InstanceState)
|
||||
}
|
||||
|
||||
// If we have no state, we don't do any refreshing
|
||||
if state == nil {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
n.Info.ModulePath = ctx.Path()
|
||||
return provider.Refresh(n.Info, state)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue