Skip to content

Commit

Permalink
Fix failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mitchellh committed Oct 10, 2014
1 parent 8aae809 commit 539eca5
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 20 deletions.
16 changes: 0 additions & 16 deletions builtin/providers/aws/structure_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -241,19 +241,3 @@ func Test_expandStringList(t *testing.T) {
}

}

func Test_expandStringListWildcard(t *testing.T) {
stringList := expandStringList([]interface{}{"us-east-1a,us-east-1b"})
expected := []string{
"us-east-1a",
"us-east-1b",
}

if !reflect.DeepEqual(stringList, expected) {
t.Fatalf(
"Got:\n\n%#v\n\nExpected:\n\n%#v\n",
stringList,
expected)
}

}
4 changes: 2 additions & 2 deletions builtin/provisioners/remote-exec/resource_provisioner_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ func TestResourceProvider_Validate_bad(t *testing.T) {
func TestResourceProvider_generateScript(t *testing.T) {
p := new(ResourceProvisioner)
conf := testConfig(t, map[string]interface{}{
"inline": []string{
"inline": []interface{}{
"cd /tmp",
"wget http://foobar",
"exit 0",
Expand All @@ -69,7 +69,7 @@ exit 0
func TestResourceProvider_CollectScripts_inline(t *testing.T) {
p := new(ResourceProvisioner)
conf := testConfig(t, map[string]interface{}{
"inline": []string{
"inline": []interface{}{
"cd /tmp",
"wget http://foobar",
"exit 0",
Expand Down
4 changes: 2 additions & 2 deletions helper/config/validator_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ func TestValidator_array(t *testing.T) {
// Valid
c = testConfig(t, map[string]interface{}{
"foo": "bar",
"nested": []string{"foo", "bar"},
"nested": []interface{}{"foo", "bar"},
})
testValid(v, c)

Expand Down Expand Up @@ -124,7 +124,7 @@ func TestValidator_complexNested(t *testing.T) {
"ingress": []map[string]interface{}{
map[string]interface{}{
"from_port": "80",
"cidr_blocks": []string{"foo"},
"cidr_blocks": []interface{}{"foo"},
},
},
})
Expand Down

0 comments on commit 539eca5

Please sign in to comment.