Fix failing tests

This commit is contained in:
Mitchell Hashimoto 2014-10-09 21:29:21 -07:00
parent 8aae8099e8
commit 539eca5ee6
3 changed files with 4 additions and 20 deletions

View File

@ -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)
}
}

View File

@ -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",
@ -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",

View File

@ -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)
@ -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"},
},
},
})