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

Implement End-To-End Testing for Session Handling #2

Closed
bflad opened this issue Feb 27, 2019 · 2 comments
Closed

Implement End-To-End Testing for Session Handling #2

bflad opened this issue Feb 27, 2019 · 2 comments
Labels
Milestone

Comments

@bflad
Copy link
Contributor

bflad commented Feb 27, 2019

Description

The migrated code from https://github.com/github.com/terraform-providers/terraform-provider-aws never included end-to-end testing for the AWS Go SDK credential ordering and session construction.

It should be possible to assemble testing similar to https://github.com/aws/aws-sdk-go/blob/5b6de26cd5565bb7349fc12593b83ddc5ce343e0/aws/session/session_test.go to ensure updates to this codebase do not cause unexpected behavior or regressions.

@aeschright
Copy link
Contributor

First round of tests merged in #9. Still to do: cover AssumeRole and address any needed integration testing.

bflad added a commit that referenced this issue Jun 2, 2020
…t customization bugs (#32)

Reference: #2
Reference: hashicorp/terraform-provider-aws#9869
Reference: hashicorp/terraform#25056

Practitioner facing changes:

- Properly use custom STS endpoint during AssumeRole API calls triggered by Terraform AWS Provider and S3 Backend configurations
- Properly use custom EC2 metadata endpoint during API calls triggered by fallback credentials lookup

Other changes:

- Use Go 1.13 wrapped error handling
- Introduce centralized endpoints.Resolver for custom endpoint handling
- Introduce mock ECS credentials server
- Introduce STS AssumeRole valid and invalid API responses
@bflad bflad added this to the v0.5.0 milestone Jun 2, 2020
@bflad bflad added the tests label Jun 2, 2020
@bflad
Copy link
Contributor Author

bflad commented Jun 2, 2020

More unit testing has been added via #32 -- closing for more targeted issues, if necessary. 👍

@bflad bflad closed this as completed Jun 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants