diff --git a/smithy-aws-protocol-tests/model/restJson1/http-headers.smithy b/smithy-aws-protocol-tests/model/restJson1/http-headers.smithy index c9606fbc449..62e6639cada 100644 --- a/smithy-aws-protocol-tests/model/restJson1/http-headers.smithy +++ b/smithy-aws-protocol-tests/model/restJson1/http-headers.smithy @@ -46,6 +46,21 @@ apply InputAndOutputWithHeaders @httpRequestTests([ headerStringSet: ["a", "b", "c"], } }, + { + id: "RestJsonInputAndOutputWithQuotedStringHeaders", + documentation: "Tests requests with string list header bindings that require quoting", + protocol: restJson1, + method: "POST", + uri: "/InputAndOutputWithHeaders", + headers: { + "X-StringList": """ + "b,c","\"def\"",a""" + }, + body: "", + params: { + headerStringList: ["b,c", "\"def\"", "a"] + } + }, { id: "RestJsonInputAndOutputWithNumericHeaders", documentation: "Tests requests with numeric header bindings", @@ -97,7 +112,7 @@ apply InputAndOutputWithHeaders @httpRequestTests([ method: "POST", uri: "/InputAndOutputWithHeaders", headers: { - "X-TimestampList": "Mon, 16 Dec 2019 23:48:18 GMT, Mon, 16 Dec 2019 23:48:18 GMT" + "X-TimestampList": "\"Mon, 16 Dec 2019 23:48:18 GMT\", \"Mon, 16 Dec 2019 23:48:18 GMT\"" }, body: "", params: { @@ -187,6 +202,19 @@ apply InputAndOutputWithHeaders @httpResponseTests([ headerStringSet: ["a", "b", "c"], } }, + { + id: "RestJsonInputAndOutputWithQuotedStringHeaders", + documentation: "Tests responses with string list header bindings that require quoting", + protocol: restJson1, + code: 200, + headers: { + "X-StringList": """ + "b,c","\"def\"",a""" + }, + params: { + headerStringList: ["a", "b,c", "\"def\""] + } + }, { id: "RestJsonInputAndOutputWithNumericHeaders", documentation: "Tests responses with numeric header bindings", @@ -233,7 +261,7 @@ apply InputAndOutputWithHeaders @httpResponseTests([ protocol: restJson1, code: 200, headers: { - "X-TimestampList": "Mon, 16 Dec 2019 23:48:18 GMT, Mon, 16 Dec 2019 23:48:18 GMT" + "X-TimestampList": "\"Mon, 16 Dec 2019 23:48:18 GMT\", \"Mon, 16 Dec 2019 23:48:18 GMT\"" }, params: { headerTimestampList: [1576540098, 1576540098]