Skip to content

Conversation

smilkuri
Copy link
Contributor

@smilkuri smilkuri commented Sep 17, 2025

Issue

Internal P293169653

Description

The integration test was failing due to changes in the model.json, because the test assertions were too precise and expected
exact values.

  • Updated X-Amz-Date regex from \d{8}T\d+Z to \d{8}T\d{6}Z for precise timestamp format
  • Updated X-Amz-Signature regex from (.*?) to [a-f0-9]+ for hex signature validation
  • Updated X-Amz-SignedHeaders regex to accept both 'host' and '%3Aauthority' values

Testing

For existing model

dev-dsk-smilkuri-1a-17aece6b % yarn test:integration

 RUN  v3.2.4 /local/home/smilkuri/aws-sdk-js-v3/packages/polly-request-presigner

 ✓ src/polly-request-presigner.integ.spec.ts (1 test) 19ms
   ✓ polly-request-presigner > should sign URLs 18ms

 Test Files  1 passed (1)
      Tests  1 passed (1)
   Start at  19:23:50
   Duration  558ms (transform 130ms, setup 0ms, collect 225ms, tests 19ms, environment 0ms, prepare 133ms)
   

For new model

Regenerated and built the client for latest model and tested it with yarn test:integartion

$ b client polly - gen,b

dev-dsk-smilkuri-1a-17aece6b % yarn test:integration

 RUN  v3.2.4 /local/home/smilkuri/aws-sdk-js-v3/packages/polly-request-presigner

 ✓ src/polly-request-presigner.integ.spec.ts (1 test) 19ms
   ✓ polly-request-presigner > should sign URLs 18ms

 Test Files  1 passed (1)
      Tests  1 passed (1)
   Start at  19:36:39
   Duration  562ms (transform 130ms, setup 0ms, collect 237ms, tests 19ms, environment 0ms, prepare 122ms)

Additional context

Add any other context about the PR here.

Checklist

  • [n/a] If the PR is a feature, add integration tests (*.integ.spec.ts).
  • [n/a] If you wrote E2E tests, are they resilient to concurrent I/O?
  • [n/a] If adding new public functions, did you add the @public tag and enable doc generation on the package?

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@smilkuri smilkuri requested a review from a team as a code owner September 17, 2025 19:41
@smilkuri smilkuri merged commit 5a1cd73 into main Sep 17, 2025
6 checks passed
@trivikr trivikr deleted the fix/polly-integ-test branch September 18, 2025 15:25
Copy link

github-actions bot commented Oct 3, 2025

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 3, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants