Add forgotten test

This commit is contained in:
Jeff Mitchell 2016-03-15 14:18:35 -04:00
parent 8bf935bc2b
commit 8aaf29b78d

View file

@ -252,6 +252,19 @@ func testAccStepListCerts(
Operation: logical.ListOperation,
Path: "certs/",
Check: func(resp *logical.Response) error {
if resp == nil {
return fmt.Errorf("nil response")
}
if resp.Data == nil {
return fmt.Errorf("nil data")
}
if resp.Data["keys"] == interface{}(nil) {
return fmt.Errorf("nil keys")
}
keys := resp.Data["keys"].([]string)
if !reflect.DeepEqual(keys, certs) {
return fmt.Errorf("mismatch: keys is %#v, certs is %#v", keys, certs)
}
return nil
},