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

s3control: Fix equivalent policy diffs #22255

Merged
merged 9 commits into from
Dec 16, 2021
Merged

Conversation

YakDriver
Copy link
Member

@YakDriver YakDriver commented Dec 16, 2021

Community Note

  • Please vote on this pull request by adding a 👍 reaction to the original pull request comment to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for pull request followers and do not help prioritize the request

Relates #21968
Closes #21795

Output from acceptance testing (us-west-2)

% make testacc TESTS="TestAccSecretsManagerSecret_|TestAccSecretsManagerSecretPolicy_" PKG=secretsmanager
--- PASS: TestAccSecretsManagerSecret_withNamePrefix (27.45s)
--- PASS: TestAccSecretsManagerSecret_basic (27.56s)
--- PASS: TestAccSecretsManagerSecret_basicReplica (28.94s)
--- PASS: TestAccSecretsManagerSecret_RecoveryWindowInDays_recreate (40.81s)
--- PASS: TestAccSecretsManagerSecret_description (42.51s)
--- PASS: TestAccSecretsManagerSecret_kmsKeyID (49.08s)
--- PASS: TestAccSecretsManagerSecret_policy (66.69s)
--- PASS: TestAccSecretsManagerSecret_tags (67.46s)
--- PASS: TestAccSecretsManagerSecret_overwriteReplica (70.49s)
--- PASS: TestAccSecretsManagerSecret_rotationRules (72.50s)
--- PASS: TestAccSecretsManagerSecret_rotationLambdaARN (96.55s)
--- PASS: TestAccSecretsManagerSecretPolicy_disappears (35.69s)
--- PASS: TestAccSecretsManagerSecretPolicy_basic (66.13s)
--- PASS: TestAccSecretsManagerSecretPolicy_blockPublicPolicy (107.63s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/secretsmanager	101.795s
% make testacc TESTS="TestAccS3ControlAccessPoint_|TestAccS3ControlAccessPointPolicy_|TestAccS3ControlBucketPolicy_|TestAccS3ControlMultiRegionAccessPointPolicy_|TestAccS3ControlObjectLambdaAccessPointPolicy_" PKG=s3control
--- SKIP: TestAccS3ControlBucketPolicy_policy (2.27s)
--- SKIP: TestAccS3ControlBucketPolicy_basic (2.32s)
--- SKIP: TestAccS3ControlAccessPoint_Bucket_arn (2.49s)
--- SKIP: TestAccS3ControlBucketPolicy_disappears (2.86s)
--- PASS: TestAccS3ControlAccessPoint_disappears (42.22s)
--- PASS: TestAccS3ControlAccessPointPolicy_disappears_AccessPoint (45.89s)
--- PASS: TestAccS3ControlAccessPointPolicy_disappears (44.09s)
--- PASS: TestAccS3ControlAccessPoint_publicAccessBlock (46.99s)
--- PASS: TestAccS3ControlAccessPoint_vpc (47.12s)
--- PASS: TestAccS3ControlAccessPoint_basic (47.51s)
--- PASS: TestAccS3ControlAccessPointPolicy_basic (50.63s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_disappears (59.39s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_Disappears_accessPoint (65.26s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_basic (75.74s)
--- PASS: TestAccS3ControlAccessPointPolicy_update (81.95s)
--- PASS: TestAccS3ControlAccessPoint_policy (120.92s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_update (134.77s)
--- PASS: TestAccS3ControlMultiRegionAccessPointPolicy_basic (285.50s)
--- PASS: TestAccS3ControlMultiRegionAccessPointPolicy_disappears_MultiRegionAccessPoint (292.58s)
--- PASS: TestAccS3ControlMultiRegionAccessPointPolicy_details_policy (398.35s)
--- PASS: TestAccS3ControlMultiRegionAccessPointPolicy_details_name (571.79s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/s3control	573.595s

Output from acceptance testing (GovCloud)

--- SKIP: TestAccSecretsManagerSecret_overwriteReplica (2.61s)
--- PASS: TestAccSecretsManagerSecret_withNamePrefix (34.17s)
--- PASS: TestAccSecretsManagerSecret_basic (34.19s)
--- PASS: TestAccSecretsManagerSecret_basicReplica (36.87s)
--- PASS: TestAccSecretsManagerSecret_RecoveryWindowInDays_recreate (50.56s)
--- PASS: TestAccSecretsManagerSecret_description (54.15s)
--- PASS: TestAccSecretsManagerSecret_kmsKeyID (63.09s)
--- PASS: TestAccSecretsManagerSecret_rotationLambdaARN (82.30s)
--- PASS: TestAccSecretsManagerSecret_policy (89.56s)
--- PASS: TestAccSecretsManagerSecret_rotationRules (93.71s)
--- PASS: TestAccSecretsManagerSecret_tags (98.24s)

--- PASS: TestAccSecretsManagerSecretPolicy_disappears (46.28s)
--- PASS: TestAccSecretsManagerSecretPolicy_basic (79.72s)
--- PASS: TestAccSecretsManagerSecretPolicy_blockPublicPolicy (95.03s)

--- SKIP: TestAccS3ControlAccessPoint_Bucket_arn (2.59s)
--- SKIP: TestAccS3ControlBucketPolicy_policy (2.64s)
--- SKIP: TestAccS3ControlBucketPolicy_basic (2.91s)
--- SKIP: TestAccS3ControlBucketPolicy_disappears (8.62s)
--- PASS: TestAccS3ControlAccessPoint_disappears (44.67s)
--- PASS: TestAccS3ControlAccessPointPolicy_disappears_AccessPoint (49.05s)
--- PASS: TestAccS3ControlAccessPointPolicy_disappears (49.63s)
--- PASS: TestAccS3ControlAccessPoint_publicAccessBlock (51.40s)
--- PASS: TestAccS3ControlAccessPoint_basic (51.69s)
--- PASS: TestAccS3ControlAccessPoint_vpc (52.15s)
--- PASS: TestAccS3ControlAccessPointPolicy_basic (55.96s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_Disappears_accessPoint (64.09s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_disappears (69.87s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_basic (78.26s)
--- PASS: TestAccS3ControlAccessPointPolicy_update (88.66s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_update (95.36s)
--- PASS: TestAccS3ControlAccessPoint_policy (120.35s)

@github-actions github-actions bot added size/XS Managed by automation to categorize the size of a PR. service/s3control Issues and PRs that pertain to the s3control service. labels Dec 16, 2021
@YakDriver YakDriver marked this pull request as draft December 16, 2021 15:16
@YakDriver YakDriver changed the title s3control: Fix equivalent policy diffs [WIP] s3control: Fix equivalent policy diffs Dec 16, 2021
@github-actions github-actions bot added size/M Managed by automation to categorize the size of a PR. documentation Introduces or discusses updates to documentation. service/secretsmanager Issues and PRs that pertain to the secretsmanager service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. and removed size/XS Managed by automation to categorize the size of a PR. labels Dec 16, 2021
@github-actions github-actions bot added size/L Managed by automation to categorize the size of a PR. and removed size/M Managed by automation to categorize the size of a PR. labels Dec 16, 2021
@YakDriver YakDriver marked this pull request as ready for review December 16, 2021 20:45
@YakDriver YakDriver changed the title [WIP] s3control: Fix equivalent policy diffs s3control: Fix equivalent policy diffs Dec 16, 2021
Copy link
Contributor

@ewbankkit ewbankkit left a comment

Choose a reason for hiding this comment

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

LGTM 🚀.

% make testacc TESTARGS='-run=TestAccS3ControlAccessPoint_\|TestAccS3ControlAccessPointPolicy_\|TestAccS3ControlBucketPolicy_\|TestAccS3ControlMultiRegionAccessPointPolicy_\|TestAccS3ControlObjectLambdaAccessPointPolicy_' PKG=s3control
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/s3control/... -v -count 1 -parallel 20 -run=TestAccS3ControlAccessPoint_\|TestAccS3ControlAccessPointPolicy_\|TestAccS3ControlBucketPolicy_\|TestAccS3ControlMultiRegionAccessPointPolicy_\|TestAccS3ControlObjectLambdaAccessPointPolicy_ -timeout 180m
=== RUN   TestAccS3ControlAccessPointPolicy_basic
=== PAUSE TestAccS3ControlAccessPointPolicy_basic
=== RUN   TestAccS3ControlAccessPointPolicy_disappears
=== PAUSE TestAccS3ControlAccessPointPolicy_disappears
=== RUN   TestAccS3ControlAccessPointPolicy_disappears_AccessPoint
=== PAUSE TestAccS3ControlAccessPointPolicy_disappears_AccessPoint
=== RUN   TestAccS3ControlAccessPointPolicy_update
=== PAUSE TestAccS3ControlAccessPointPolicy_update
=== RUN   TestAccS3ControlAccessPoint_basic
=== PAUSE TestAccS3ControlAccessPoint_basic
=== RUN   TestAccS3ControlAccessPoint_disappears
=== PAUSE TestAccS3ControlAccessPoint_disappears
=== RUN   TestAccS3ControlAccessPoint_Bucket_arn
=== PAUSE TestAccS3ControlAccessPoint_Bucket_arn
=== RUN   TestAccS3ControlAccessPoint_policy
=== PAUSE TestAccS3ControlAccessPoint_policy
=== RUN   TestAccS3ControlAccessPoint_publicAccessBlock
=== PAUSE TestAccS3ControlAccessPoint_publicAccessBlock
=== RUN   TestAccS3ControlAccessPoint_vpc
=== PAUSE TestAccS3ControlAccessPoint_vpc
=== RUN   TestAccS3ControlBucketPolicy_basic
=== PAUSE TestAccS3ControlBucketPolicy_basic
=== RUN   TestAccS3ControlBucketPolicy_disappears
=== PAUSE TestAccS3ControlBucketPolicy_disappears
=== RUN   TestAccS3ControlBucketPolicy_policy
=== PAUSE TestAccS3ControlBucketPolicy_policy
=== RUN   TestAccS3ControlMultiRegionAccessPointPolicy_basic
=== PAUSE TestAccS3ControlMultiRegionAccessPointPolicy_basic
=== RUN   TestAccS3ControlMultiRegionAccessPointPolicy_disappears_MultiRegionAccessPoint
=== PAUSE TestAccS3ControlMultiRegionAccessPointPolicy_disappears_MultiRegionAccessPoint
=== RUN   TestAccS3ControlMultiRegionAccessPointPolicy_details_policy
=== PAUSE TestAccS3ControlMultiRegionAccessPointPolicy_details_policy
=== RUN   TestAccS3ControlMultiRegionAccessPointPolicy_details_name
=== PAUSE TestAccS3ControlMultiRegionAccessPointPolicy_details_name
=== RUN   TestAccS3ControlObjectLambdaAccessPointPolicy_basic
=== PAUSE TestAccS3ControlObjectLambdaAccessPointPolicy_basic
=== RUN   TestAccS3ControlObjectLambdaAccessPointPolicy_disappears
=== PAUSE TestAccS3ControlObjectLambdaAccessPointPolicy_disappears
=== RUN   TestAccS3ControlObjectLambdaAccessPointPolicy_Disappears_accessPoint
=== PAUSE TestAccS3ControlObjectLambdaAccessPointPolicy_Disappears_accessPoint
=== RUN   TestAccS3ControlObjectLambdaAccessPointPolicy_update
=== PAUSE TestAccS3ControlObjectLambdaAccessPointPolicy_update
=== CONT  TestAccS3ControlAccessPointPolicy_basic
=== CONT  TestAccS3ControlBucketPolicy_disappears
=== CONT  TestAccS3ControlAccessPoint_policy
=== CONT  TestAccS3ControlMultiRegionAccessPointPolicy_basic
=== CONT  TestAccS3ControlAccessPoint_Bucket_arn
=== CONT  TestAccS3ControlBucketPolicy_basic
=== CONT  TestAccS3ControlAccessPoint_vpc
=== CONT  TestAccS3ControlAccessPoint_publicAccessBlock
=== CONT  TestAccS3ControlObjectLambdaAccessPointPolicy_update
=== CONT  TestAccS3ControlObjectLambdaAccessPointPolicy_basic
=== CONT  TestAccS3ControlObjectLambdaAccessPointPolicy_Disappears_accessPoint
=== CONT  TestAccS3ControlMultiRegionAccessPointPolicy_disappears_MultiRegionAccessPoint
=== CONT  TestAccS3ControlMultiRegionAccessPointPolicy_details_name
=== CONT  TestAccS3ControlObjectLambdaAccessPointPolicy_disappears
=== CONT  TestAccS3ControlAccessPointPolicy_update
=== CONT  TestAccS3ControlAccessPoint_disappears
=== CONT  TestAccS3ControlBucketPolicy_policy
=== CONT  TestAccS3ControlAccessPoint_basic
=== CONT  TestAccS3ControlMultiRegionAccessPointPolicy_details_policy
=== CONT  TestAccS3ControlAccessPointPolicy_disappears
=== CONT  TestAccS3ControlAccessPoint_Bucket_arn
    acctest.go:1254: skipping since no Outposts found
--- SKIP: TestAccS3ControlAccessPoint_Bucket_arn (2.02s)
=== CONT  TestAccS3ControlAccessPointPolicy_disappears_AccessPoint
=== CONT  TestAccS3ControlBucketPolicy_policy
    acctest.go:1254: skipping since no Outposts found
--- SKIP: TestAccS3ControlBucketPolicy_policy (2.04s)
=== CONT  TestAccS3ControlBucketPolicy_disappears
    acctest.go:1254: skipping since no Outposts found
--- SKIP: TestAccS3ControlBucketPolicy_disappears (8.21s)
=== CONT  TestAccS3ControlBucketPolicy_basic
    acctest.go:1254: skipping since no Outposts found
--- SKIP: TestAccS3ControlBucketPolicy_basic (8.30s)
--- PASS: TestAccS3ControlAccessPoint_disappears (25.71s)
--- PASS: TestAccS3ControlAccessPoint_vpc (27.01s)
--- PASS: TestAccS3ControlAccessPointPolicy_disappears_AccessPoint (26.12s)
--- PASS: TestAccS3ControlAccessPointPolicy_disappears (28.72s)
--- PASS: TestAccS3ControlAccessPoint_publicAccessBlock (28.84s)
--- PASS: TestAccS3ControlAccessPoint_basic (30.56s)
--- PASS: TestAccS3ControlAccessPointPolicy_basic (30.70s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_basic (41.82s)
--- PASS: TestAccS3ControlAccessPointPolicy_update (42.28s)
--- PASS: TestAccS3ControlAccessPoint_policy (54.51s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_Disappears_accessPoint (55.90s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_disappears (58.47s)
--- PASS: TestAccS3ControlObjectLambdaAccessPointPolicy_update (67.64s)
--- PASS: TestAccS3ControlMultiRegionAccessPointPolicy_disappears_MultiRegionAccessPoint (148.17s)
--- PASS: TestAccS3ControlMultiRegionAccessPointPolicy_basic (213.77s)
--- PASS: TestAccS3ControlMultiRegionAccessPointPolicy_details_policy (317.53s)
--- PASS: TestAccS3ControlMultiRegionAccessPointPolicy_details_name (348.62s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/s3control	352.110s
% make testacc TESTARGS='-run=TestAccSecretsManagerSecret_\|TestAccSecretsManagerSecretPolicy_' PKG=secretsmanager
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/secretsmanager/... -v -count 1 -parallel 20 -run=TestAccSecretsManagerSecret_\|TestAccSecretsManagerSecretPolicy_ -timeout 180m
=== RUN   TestAccSecretsManagerSecretPolicy_basic
=== PAUSE TestAccSecretsManagerSecretPolicy_basic
=== RUN   TestAccSecretsManagerSecretPolicy_blockPublicPolicy
=== PAUSE TestAccSecretsManagerSecretPolicy_blockPublicPolicy
=== RUN   TestAccSecretsManagerSecretPolicy_disappears
=== PAUSE TestAccSecretsManagerSecretPolicy_disappears
=== RUN   TestAccSecretsManagerSecret_basic
=== PAUSE TestAccSecretsManagerSecret_basic
=== RUN   TestAccSecretsManagerSecret_withNamePrefix
=== PAUSE TestAccSecretsManagerSecret_withNamePrefix
=== RUN   TestAccSecretsManagerSecret_description
=== PAUSE TestAccSecretsManagerSecret_description
=== RUN   TestAccSecretsManagerSecret_basicReplica
=== PAUSE TestAccSecretsManagerSecret_basicReplica
=== RUN   TestAccSecretsManagerSecret_overwriteReplica
=== PAUSE TestAccSecretsManagerSecret_overwriteReplica
=== RUN   TestAccSecretsManagerSecret_kmsKeyID
=== PAUSE TestAccSecretsManagerSecret_kmsKeyID
=== RUN   TestAccSecretsManagerSecret_RecoveryWindowInDays_recreate
=== PAUSE TestAccSecretsManagerSecret_RecoveryWindowInDays_recreate
=== RUN   TestAccSecretsManagerSecret_rotationLambdaARN
=== PAUSE TestAccSecretsManagerSecret_rotationLambdaARN
=== RUN   TestAccSecretsManagerSecret_rotationRules
=== PAUSE TestAccSecretsManagerSecret_rotationRules
=== RUN   TestAccSecretsManagerSecret_tags
=== PAUSE TestAccSecretsManagerSecret_tags
=== RUN   TestAccSecretsManagerSecret_policy
=== PAUSE TestAccSecretsManagerSecret_policy
=== CONT  TestAccSecretsManagerSecretPolicy_basic
=== CONT  TestAccSecretsManagerSecret_kmsKeyID
=== CONT  TestAccSecretsManagerSecretPolicy_blockPublicPolicy
=== CONT  TestAccSecretsManagerSecret_withNamePrefix
=== CONT  TestAccSecretsManagerSecret_description
=== CONT  TestAccSecretsManagerSecret_overwriteReplica
=== CONT  TestAccSecretsManagerSecret_basicReplica
=== CONT  TestAccSecretsManagerSecret_tags
=== CONT  TestAccSecretsManagerSecretPolicy_disappears
=== CONT  TestAccSecretsManagerSecret_basic
=== CONT  TestAccSecretsManagerSecret_rotationLambdaARN
=== CONT  TestAccSecretsManagerSecret_policy
=== CONT  TestAccSecretsManagerSecret_RecoveryWindowInDays_recreate
=== CONT  TestAccSecretsManagerSecret_rotationRules
--- PASS: TestAccSecretsManagerSecret_basic (27.71s)
--- PASS: TestAccSecretsManagerSecret_withNamePrefix (27.81s)
--- PASS: TestAccSecretsManagerSecret_basicReplica (27.98s)
--- PASS: TestAccSecretsManagerSecret_RecoveryWindowInDays_recreate (39.40s)
--- PASS: TestAccSecretsManagerSecret_description (43.31s)
--- PASS: TestAccSecretsManagerSecret_kmsKeyID (48.52s)
--- PASS: TestAccSecretsManagerSecretPolicy_basic (61.22s)
--- PASS: TestAccSecretsManagerSecretPolicy_disappears (62.64s)
--- PASS: TestAccSecretsManagerSecret_tags (68.53s)
--- PASS: TestAccSecretsManagerSecret_overwriteReplica (70.87s)
--- PASS: TestAccSecretsManagerSecret_rotationLambdaARN (71.39s)
--- PASS: TestAccSecretsManagerSecret_policy (81.86s)
--- PASS: TestAccSecretsManagerSecretPolicy_blockPublicPolicy (84.05s)
--- PASS: TestAccSecretsManagerSecret_rotationRules (86.55s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/secretsmanager	89.867s

@YakDriver YakDriver merged commit 15356c9 into main Dec 16, 2021
@YakDriver YakDriver deleted the b-s3control-policy-diffs branch December 16, 2021 21:29
@github-actions github-actions bot added this to the v3.70.0 milestone Dec 16, 2021
github-actions bot pushed a commit that referenced this pull request Dec 16, 2021
@github-actions
Copy link

This functionality has been released in v3.70.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

@github-actions
Copy link

github-actions bot commented Jun 2, 2022

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 2, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Introduces or discusses updates to documentation. service/s3control Issues and PRs that pertain to the s3control service. service/secretsmanager Issues and PRs that pertain to the secretsmanager service. size/L Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
2 participants