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

Add test to exercise excluded headers in aws-sigv4 #1890

Merged
merged 4 commits into from
Oct 21, 2022

Conversation

ysaito1001
Copy link
Contributor

@ysaito1001 ysaito1001 commented Oct 21, 2022

Motivation and Context

This commit addresses #1392 by adding a test for the functionality introduced in #1381.

Description

Prior to this PR, there was an existing test presigning_header_exclusion that exercised the said functionality but it only covered the behavior partially, i.e. only a case where the excluded_headers field in SigningSettings contained just user-agent. The new test is a proptest and will randomly add headers to excluded_headers to verify the functionality works as expected.

Testing

Ran cargo t within the aws-sigv4 crate.

Checklist

  • I have updated CHANGELOG.next.toml if I made changes to the AWS SDK, generated SDK code, or SDK runtime crates

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

Saito added 2 commits October 21, 2022 10:05
This commit adds a test for the functionality added in #1381. Technically,
there was an existing test `presigning_header_exclusion` that exercised
the said functionality but it only covered the behavior partially, i.e.
only a case where the `excluded_headers` field in `SigningSettings`
contained just `user-agent`.

The new test will randomly add headers to `excluded_headers` and verify
the functionality works as expected.
@ysaito1001 ysaito1001 marked this pull request as ready for review October 21, 2022 15:22
@ysaito1001 ysaito1001 requested review from a team as code owners October 21, 2022 15:22
@github-actions
Copy link

A new generated diff is ready to view.

A new doc preview is ready to view.

Copy link
Collaborator

@jdisanti jdisanti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

CHANGELOG.next.toml Outdated Show resolved Hide resolved
Co-authored-by: John DiSanti <jdisanti@amazon.com>
@github-actions
Copy link

A new generated diff is ready to view.

A new doc preview is ready to view.

@github-actions
Copy link

A new generated diff is ready to view.

A new doc preview is ready to view.

@ysaito1001 ysaito1001 enabled auto-merge (squash) October 21, 2022 20:32
@ysaito1001 ysaito1001 merged commit ca2c788 into main Oct 21, 2022
@ysaito1001 ysaito1001 deleted the ysaito/add-test-for-excluded-headers-list branch October 21, 2022 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants