From ff445d3c2631b0dab8f33ffee993771d4de77785 Mon Sep 17 00:00:00 2001 From: James Bardin Date: Wed, 1 Mar 2017 13:54:10 -0500 Subject: [PATCH] fix test that were relying on non-matching configs A couple interpolation tests were using invalid state that didn't match the config. These will still pass but were flushed out by an attempt to make this an error. The repl however still required interpolation without a config, and tests there will provide a indication if this behavior changes. --- terraform/interpolate_test.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/terraform/interpolate_test.go b/terraform/interpolate_test.go index b85f2aad45..bdadedc4fc 100644 --- a/terraform/interpolate_test.go +++ b/terraform/interpolate_test.go @@ -680,7 +680,7 @@ func TestInterpolator_interpolatedListOrder(t *testing.T) { &ModuleState{ Path: rootModulePath, Resources: map[string]*ResourceState{ - "aws_route53_zone.list": &ResourceState{ + "aws_route53_zone.yada": &ResourceState{ Type: "aws_route53_zone", Dependencies: []string{}, Primary: &InstanceState{ @@ -719,7 +719,7 @@ func TestInterpolator_interpolatedListOrder(t *testing.T) { list := []interface{}{"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l"} - testInterpolate(t, i, scope, "aws_route53_zone.list.foo", + testInterpolate(t, i, scope, "aws_route53_zone.yada.foo", interfaceToVariableSwallowError(list)) } @@ -844,7 +844,7 @@ func TestInterpolator_sets(t *testing.T) { &ModuleState{ Path: rootModulePath, Resources: map[string]*ResourceState{ - "aws_network_interface.set": &ResourceState{ + "aws_route53_zone.yada": &ResourceState{ Type: "aws_network_interface", Dependencies: []string{}, Primary: &InstanceState{ @@ -872,7 +872,7 @@ func TestInterpolator_sets(t *testing.T) { set := []interface{}{"10.42.16.179"} - testInterpolate(t, i, scope, "aws_network_interface.set.private_ips", + testInterpolate(t, i, scope, "aws_route53_zone.yada.private_ips", interfaceToVariableSwallowError(set)) }