Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test(protocoltests): enable request compression tests #6011

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -305,13 +305,6 @@ private static boolean filterProtocolTests(
HttpMessageTestCase testCase,
TypeScriptSettings settings
) {
// TODO: Remove when requestCompression has been implemented.
if (testCase.getId().startsWith("SDKAppliedContentEncoding_")
|| testCase.getId().startsWith("SDKAppendsGzipAndIgnoresHttpProvidedEncoding_")
|| testCase.getId().startsWith("SDKAppendedGzipAfterProvidedEncoding_")) {
return true;
}

if (testCase.getTags().contains("defaults")) {
return true;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -780,7 +780,7 @@ it("Ec2QueryNoInputAndOutput:Response", async () => {
/**
* Compression algorithm encoding is appended to the Content-Encoding header.
*/
it.skip("SDKAppliedContentEncoding_ec2Query:Request", async () => {
it("SDKAppliedContentEncoding_ec2Query:Request", async () => {
const client = new EC2ProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down Expand Up @@ -813,7 +813,7 @@ it.skip("SDKAppliedContentEncoding_ec2Query:Request", async () => {
* traits are ignored in the ec2Query protocol.
*
*/
it.skip("SDKAppendsGzipAndIgnoresHttpProvidedEncoding_ec2Query:Request", async () => {
it("SDKAppendsGzipAndIgnoresHttpProvidedEncoding_ec2Query:Request", async () => {
const client = new EC2ProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2811,7 +2811,7 @@ it.skip("AwsJson10ClientErrorCorrectsWhenServerFailsToSerializeRequiredValues:Re
/**
* Compression algorithm encoding is appended to the Content-Encoding header.
*/
it.skip("SDKAppliedContentEncoding_awsJson1_0:Request", async () => {
it("SDKAppliedContentEncoding_awsJson1_0:Request", async () => {
const client = new JSONRPC10Client({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down Expand Up @@ -2844,7 +2844,7 @@ it.skip("SDKAppliedContentEncoding_awsJson1_0:Request", async () => {
* traits are ignored in the awsJson1_0 protocol.
*
*/
it.skip("SDKAppendsGzipAndIgnoresHttpProvidedEncoding_awsJson1_0:Request", async () => {
it("SDKAppendsGzipAndIgnoresHttpProvidedEncoding_awsJson1_0:Request", async () => {
const client = new JSONRPC10Client({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4389,7 +4389,7 @@ it("PutAndGetInlineDocumentsInput:Response", async () => {
/**
* Compression algorithm encoding is appended to the Content-Encoding header.
*/
it.skip("SDKAppliedContentEncoding_awsJson1_1:Request", async () => {
it("SDKAppliedContentEncoding_awsJson1_1:Request", async () => {
const client = new JsonProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down Expand Up @@ -4422,7 +4422,7 @@ it.skip("SDKAppliedContentEncoding_awsJson1_1:Request", async () => {
* traits are ignored in the awsJson1_1 protocol.
*
*/
it.skip("SDKAppendsGzipAndIgnoresHttpProvidedEncoding_awsJson1_1:Request", async () => {
it("SDKAppendsGzipAndIgnoresHttpProvidedEncoding_awsJson1_1:Request", async () => {
const client = new JsonProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1036,7 +1036,7 @@ it("QueryNoInputAndOutput:Response", async () => {
/**
* Compression algorithm encoding is appended to the Content-Encoding header.
*/
it.skip("SDKAppliedContentEncoding_awsQuery:Request", async () => {
it("SDKAppliedContentEncoding_awsQuery:Request", async () => {
const client = new QueryProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down Expand Up @@ -1069,7 +1069,7 @@ it.skip("SDKAppliedContentEncoding_awsQuery:Request", async () => {
* traits are ignored in the awsQuery protocol.
*
*/
it.skip("SDKAppendsGzipAndIgnoresHttpProvidedEncoding_awsQuery:Request", async () => {
it("SDKAppendsGzipAndIgnoresHttpProvidedEncoding_awsQuery:Request", async () => {
const client = new QueryProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7404,7 +7404,7 @@ it("PostUnionWithJsonNameResponse3:Response", async () => {
/**
* Compression algorithm encoding is appended to the Content-Encoding header.
*/
it.skip("SDKAppliedContentEncoding_restJson1:Request", async () => {
it("SDKAppliedContentEncoding_restJson1:Request", async () => {
const client = new RestJsonProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down Expand Up @@ -7437,7 +7437,7 @@ it.skip("SDKAppliedContentEncoding_restJson1:Request", async () => {
* request compression encoding from the HTTP binding.
*
*/
it.skip("SDKAppendedGzipAfterProvidedEncoding_restJson1:Request", async () => {
it("SDKAppendedGzipAfterProvidedEncoding_restJson1:Request", async () => {
const client = new RestJsonProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3882,7 +3882,7 @@ it("RestXmlSerializesEmptyString:Request", async () => {
/**
* Compression algorithm encoding is appended to the Content-Encoding header.
*/
it.skip("SDKAppliedContentEncoding_restXml:Request", async () => {
it("SDKAppliedContentEncoding_restXml:Request", async () => {
const client = new RestXmlProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down Expand Up @@ -3915,7 +3915,7 @@ it.skip("SDKAppliedContentEncoding_restXml:Request", async () => {
* request compression encoding from the HTTP binding.
*
*/
it.skip("SDKAppendedGzipAfterProvidedEncoding_restXml:Request", async () => {
it("SDKAppendedGzipAfterProvidedEncoding_restXml:Request", async () => {
const client = new RestXmlProtocolClient({
...clientParams,
requestHandler: new RequestSerializationTestHandler(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28364,7 +28364,7 @@ it("PostUnionWithJsonNameResponse3:ServerResponse", async () => {
/**
* Compression algorithm encoding is appended to the Content-Encoding header.
*/
it.skip("SDKAppliedContentEncoding_restJson1:ServerRequest", async () => {
it("SDKAppliedContentEncoding_restJson1:ServerRequest", async () => {
const testFunction = jest.fn();
testFunction.mockReturnValue(Promise.resolve({}));
const testService: Partial<RestJsonService<{}>> = {
Expand Down Expand Up @@ -28410,7 +28410,7 @@ it.skip("SDKAppliedContentEncoding_restJson1:ServerRequest", async () => {
* request compression encoding from the HTTP binding.
*
*/
it.skip("SDKAppendedGzipAfterProvidedEncoding_restJson1:ServerRequest", async () => {
it("SDKAppendedGzipAfterProvidedEncoding_restJson1:ServerRequest", async () => {
const testFunction = jest.fn();
testFunction.mockReturnValue(Promise.resolve({}));
const testService: Partial<RestJsonService<{}>> = {
Expand Down