Ω(resErr).ShouldNot(HaveOccurred()) expected := rsapi.APIParams{ "val": []interface{}{ rsapi.APIParams{"a": "foo", "b": "bar"}, rsapi.APIParams{"b": "baz"}, }, } Ω(res).Should(Equal(expected)) }) }) }) var _ = Describe("ParseCommand", func() { var cmd, hrefPrefix string var values rsapi.ActionCommands var api *rsapi.API var parsed *rsapi.ParsedCommand var parseErr error BeforeEach(func() { values = nil ssm := ssm.New("", nil) api = ssm.API }) JustBeforeEach(func() { parsed, parseErr = api.ParseCommand(cmd, hrefPrefix, values) }) Describe("with array of maps with one element", func() {
// Wrap generic client into API 1.5 client func fromAPI(api *rsapi.API) *API { api.Metadata = GenMetadata return &API{api} }