Add string slice with single value test function

This commit is contained in:
Jeff Mitchell 2017-06-14 14:20:37 -04:00
parent df229f5255
commit 338ebffb9d
1 changed files with 11 additions and 0 deletions

View File

@ -180,6 +180,17 @@ func TestFieldDataGet(t *testing.T) {
[]string{"123", "abc"},
},
"string slice type, single value": {
map[string]*FieldSchema{
"foo": &FieldSchema{Type: TypeStringSlice},
},
map[string]interface{}{
"foo": "abc",
},
"foo",
[]string{"abc"},
},
"comma string slice type, comma string with one value": {
map[string]*FieldSchema{
"foo": &FieldSchema{Type: TypeCommaStringSlice},