diff --git a/terraform/context_apply_test.go b/terraform/context_apply_test.go index 5f602c387..22fb220cb 100644 --- a/terraform/context_apply_test.go +++ b/terraform/context_apply_test.go @@ -4252,8 +4252,8 @@ func TestContext2Apply_Provisioner_compute(t *testing.T) { p.ApplyFn = testApplyFn p.DiffFn = testDiffFn pr.ApplyFn = func(rs *InstanceState, c *ResourceConfig) error { - val, ok := c.Config["foo"] - if !ok || val != "computed_dynamical" { + val, ok := c.Config["command"] + if !ok || val != "computed_value" { t.Fatalf("bad value for foo: %v %#v", val, c) } @@ -4825,7 +4825,7 @@ func TestContext2Apply_provisionerDestroy(t *testing.T) { p.ApplyFn = testApplyFn p.DiffFn = testDiffFn pr.ApplyFn = func(rs *InstanceState, c *ResourceConfig) error { - val, ok := c.Config["foo"] + val, ok := c.Config["command"] if !ok || val != "destroy" { t.Fatalf("bad value for foo: %v %#v", val, c) } @@ -4953,7 +4953,7 @@ func TestContext2Apply_provisionerDestroyFailContinue(t *testing.T) { var l sync.Mutex var calls []string pr.ApplyFn = func(rs *InstanceState, c *ResourceConfig) error { - val, ok := c.Config["foo"] + val, ok := c.Config["command"] if !ok { t.Fatalf("bad value for foo: %v %#v", val, c) } @@ -5029,7 +5029,7 @@ func TestContext2Apply_provisionerDestroyFailContinueFail(t *testing.T) { var l sync.Mutex var calls []string pr.ApplyFn = func(rs *InstanceState, c *ResourceConfig) error { - val, ok := c.Config["foo"] + val, ok := c.Config["command"] if !ok { t.Fatalf("bad value for foo: %v %#v", val, c) } @@ -5111,9 +5111,9 @@ func TestContext2Apply_provisionerDestroyTainted(t *testing.T) { return nil } - val, ok := c.Config["foo"] + val, ok := c.Config["command"] if !ok || val != expected { - t.Fatalf("bad value for foo: %v %#v", val, c) + t.Fatalf("bad value for command: %v %#v", val, c) } return nil diff --git a/terraform/terraform_test.go b/terraform/terraform_test.go index b1829502c..bb660e2a3 100644 --- a/terraform/terraform_test.go +++ b/terraform/terraform_test.go @@ -350,7 +350,7 @@ aws_secret_key = ZZZZ const testTerraformApplyDependsCreateBeforeStr = ` aws_instance.lb: - ID = foo + ID = baz provider = provider.aws instance = foo type = aws_instance diff --git a/terraform/test-fixtures/apply-provisioner-compute/main.tf b/terraform/test-fixtures/apply-provisioner-compute/main.tf index e503eddd5..598296501 100644 --- a/terraform/test-fixtures/apply-provisioner-compute/main.tf +++ b/terraform/test-fixtures/apply-provisioner-compute/main.tf @@ -2,12 +2,12 @@ variable "value" {} resource "aws_instance" "foo" { num = "2" - compute = "dynamical" + compute = "value" compute_value = "${var.value}" } resource "aws_instance" "bar" { provisioner "shell" { - foo = "${aws_instance.foo.dynamical}" + command = "${aws_instance.foo.value}" } } diff --git a/terraform/test-fixtures/apply-provisioner-destroy-continue/main.tf b/terraform/test-fixtures/apply-provisioner-destroy-continue/main.tf index 6f39fc0b8..0be0d331e 100644 --- a/terraform/test-fixtures/apply-provisioner-destroy-continue/main.tf +++ b/terraform/test-fixtures/apply-provisioner-destroy-continue/main.tf @@ -2,13 +2,13 @@ resource "aws_instance" "foo" { foo = "bar" provisioner "shell" { - foo = "one" + command = "one" when = "destroy" on_failure = "continue" } provisioner "shell" { - foo = "two" + command = "two" when = "destroy" on_failure = "continue" } diff --git a/terraform/test-fixtures/apply-provisioner-destroy-fail/main.tf b/terraform/test-fixtures/apply-provisioner-destroy-fail/main.tf index e756487f1..70f1c5e2a 100644 --- a/terraform/test-fixtures/apply-provisioner-destroy-fail/main.tf +++ b/terraform/test-fixtures/apply-provisioner-destroy-fail/main.tf @@ -2,13 +2,13 @@ resource "aws_instance" "foo" { foo = "bar" provisioner "shell" { - foo = "one" + command = "one" when = "destroy" on_failure = "continue" } provisioner "shell" { - foo = "two" + command = "two" when = "destroy" } } diff --git a/terraform/test-fixtures/apply-provisioner-destroy/main.tf b/terraform/test-fixtures/apply-provisioner-destroy/main.tf index 686a1b040..38410ccc0 100644 --- a/terraform/test-fixtures/apply-provisioner-destroy/main.tf +++ b/terraform/test-fixtures/apply-provisioner-destroy/main.tf @@ -2,11 +2,11 @@ resource "aws_instance" "foo" { foo = "bar" provisioner "shell" { - foo = "create" + command = "create" } provisioner "shell" { - foo = "destroy" + command = "destroy" when = "destroy" } }