-
Notifications
You must be signed in to change notification settings - Fork 9.2k
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
resource/aws_codebuild_project: Switch artifacts from TypeSet to TypeList and verify updates #9559
Conversation
…List and verify updates Reference: #755 Reference: #2050 Reference: #6214 Reference: #6427 Reference: #7582 Output from acceptance testing: ``` --- PASS: TestAccAWSCodeBuildProject_Artifacts_EncryptionDisabled (58.62s) --- PASS: TestAccAWSCodeBuildProject_Artifacts_NamespaceType (52.17s) --- PASS: TestAccAWSCodeBuildProject_Artifacts_OverrideArtifactName (51.88s) --- PASS: TestAccAWSCodeBuildProject_Artifacts_Packaging (51.20s) --- PASS: TestAccAWSCodeBuildProject_Artifacts_Path (52.22s) --- PASS: TestAccAWSCodeBuildProject_BadgeEnabled (33.85s) --- PASS: TestAccAWSCodeBuildProject_basic (24.98s) --- PASS: TestAccAWSCodeBuildProject_BuildTimeout (42.62s) --- PASS: TestAccAWSCodeBuildProject_Cache (70.42s) --- PASS: TestAccAWSCodeBuildProject_Description (42.32s) --- PASS: TestAccAWSCodeBuildProject_EncryptionKey (52.39s) --- PASS: TestAccAWSCodeBuildProject_Environment_Certificate (36.50s) --- PASS: TestAccAWSCodeBuildProject_Environment_EnvironmentVariable (55.37s) --- PASS: TestAccAWSCodeBuildProject_Environment_EnvironmentVariable_Type (30.64s) --- PASS: TestAccAWSCodeBuildProject_Environment_RegistryCredential (40.62s) --- PASS: TestAccAWSCodeBuildProject_importBasic (34.69s) --- PASS: TestAccAWSCodeBuildProject_LogsConfig_CloudWatchLogs (48.53s) --- PASS: TestAccAWSCodeBuildProject_LogsConfig_S3Logs (72.76s) --- PASS: TestAccAWSCodeBuildProject_SecondaryArtifacts (37.23s) --- PASS: TestAccAWSCodeBuildProject_SecondarySources_CodeCommit (29.35s) --- PASS: TestAccAWSCodeBuildProject_Source_Auth (30.83s) --- PASS: TestAccAWSCodeBuildProject_Source_GitCloneDepth (40.18s) --- PASS: TestAccAWSCodeBuildProject_Source_InsecureSSL (31.11s) --- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_Bitbucket (42.65s) --- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_GitHub (34.28s) --- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_GitHubEnterprise (43.13s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_Bitbucket (33.90s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_CodeCommit (34.04s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_CodePipeline (29.80s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_GitHubEnterprise (29.93s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_NoSource (33.38s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_NoSourceInvalid (12.23s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_S3 (36.44s) --- PASS: TestAccAWSCodeBuildProject_Tags (43.37s) --- PASS: TestAccAWSCodeBuildProject_VpcConfig (62.05s) --- PASS: TestAccAWSCodeBuildProject_WindowsContainer (23.75s) ```
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall this looks good to me, minus a dangling function. I left a couple of suggestions to help improve the readability of the DiffSuppressFunc, but totally optional.
--- PASS: TestAccAWSCodeBuildProject_Source_Type_CodePipeline (37.01s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_CodeCommit (37.42s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_NoSource (37.48s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_Bitbucket (38.41s)
--- PASS: TestAccAWSCodeBuildProject_WindowsContainer (38.45s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_GitHubEnterprise (38.58s)
--- PASS: TestAccAWSCodeBuildProject_SecondarySources_CodeCommit (38.64s)
--- PASS: TestAccAWSCodeBuildProject_importBasic (39.75s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_S3 (47.11s)
--- PASS: TestAccAWSCodeBuildProject_Tags (50.22s)
--- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_Bitbucket (50.26s)
--- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_GitHubEnterprise (50.26s)
--- PASS: TestAccAWSCodeBuildProject_Source_InsecureSSL (50.31s)
--- PASS: TestAccAWSCodeBuildProject_Environment_RegistryCredential (59.31s)
--- PASS: TestAccAWSCodeBuildProject_Artifacts_Path (69.38s)
--- PASS: TestAccAWSCodeBuildProject_Artifacts_Packaging (69.41s)
--- PASS: TestAccAWSCodeBuildProject_Source_Auth (34.60s)
--- PASS: TestAccAWSCodeBuildProject_Source_GitCloneDepth (37.20s)
--- PASS: TestAccAWSCodeBuildProject_SecondaryArtifacts (76.71s)
--- PASS: TestAccAWSCodeBuildProject_Environment_Certificate (37.90s)
--- PASS: TestAccAWSCodeBuildProject_VpcConfig (78.10s)
--- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_GitHub (78.25s)
--- PASS: TestAccAWSCodeBuildProject_BadgeEnabled (34.53s)
--- PASS: TestAccAWSCodeBuildProject_Environment_EnvironmentVariable_Type (38.18s)
--- PASS: TestAccAWSCodeBuildProject_LogsConfig_CloudWatchLogs (51.51s)
--- PASS: TestAccAWSCodeBuildProject_Description (45.84s)
--- PASS: TestAccAWSCodeBuildProject_Artifacts_EncryptionDisabled (60.59s)
--- PASS: TestAccAWSCodeBuildProject_Environment_EnvironmentVariable (63.23s)
--- PASS: TestAccAWSCodeBuildProject_Artifacts_NamespaceType (64.99s)
--- PASS: TestAccAWSCodeBuildProject_EncryptionKey (53.93s)
--- PASS: TestAccAWSCodeBuildProject_BuildTimeout (45.54s)
--- PASS: TestAccAWSCodeBuildProject_basic (36.18s)
--- PASS: TestAccAWSCodeBuildProject_Artifacts_OverrideArtifactName (89.57s)
--- PASS: TestAccAWSCodeBuildProject_LogsConfig_S3Logs (86.02s)
--- PASS: TestAccAWSCodeBuildProject_Cache (92.89s)
@@ -83,7 +104,6 @@ func resourceAwsCodeBuildProject() *schema.Resource { | |||
}, | |||
}, | |||
}, | |||
Set: resourceAwsCodeBuildProjectArtifactsHash, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see it in the diff, but we can probably get rid of the actual function definition as it is no longer being used.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's still used by secondary_artifacts
on line 324 and cannot be removed from there. 😉 golangci-lint
is configured to automatically report unused functions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lesson learned don't use ack
when you have a linter. 🙉 🙈 🙊
Reference: #9559 (review) Output from acceptance testing: ``` --- PASS: TestAccAWSCodeBuildProject_Artifacts_EncryptionDisabled (53.64s) --- PASS: TestAccAWSCodeBuildProject_Artifacts_NamespaceType (57.02s) --- PASS: TestAccAWSCodeBuildProject_Artifacts_OverrideArtifactName (56.85s) --- PASS: TestAccAWSCodeBuildProject_Artifacts_Packaging (56.31s) --- PASS: TestAccAWSCodeBuildProject_Artifacts_Path (61.53s) --- PASS: TestAccAWSCodeBuildProject_BadgeEnabled (30.06s) --- PASS: TestAccAWSCodeBuildProject_basic (31.13s) --- PASS: TestAccAWSCodeBuildProject_BuildTimeout (39.00s) --- PASS: TestAccAWSCodeBuildProject_Cache (65.22s) --- PASS: TestAccAWSCodeBuildProject_Description (38.67s) --- PASS: TestAccAWSCodeBuildProject_EncryptionKey (57.59s) --- PASS: TestAccAWSCodeBuildProject_Environment_Certificate (39.07s) --- PASS: TestAccAWSCodeBuildProject_Environment_EnvironmentVariable (41.42s) --- PASS: TestAccAWSCodeBuildProject_Environment_EnvironmentVariable_Type (38.48s) --- PASS: TestAccAWSCodeBuildProject_Environment_RegistryCredential (43.88s) --- PASS: TestAccAWSCodeBuildProject_importBasic (34.06s) --- PASS: TestAccAWSCodeBuildProject_LogsConfig_CloudWatchLogs (48.99s) --- PASS: TestAccAWSCodeBuildProject_LogsConfig_S3Logs (75.52s) --- PASS: TestAccAWSCodeBuildProject_SecondaryArtifacts (38.24s) --- PASS: TestAccAWSCodeBuildProject_SecondarySources_CodeCommit (33.84s) --- PASS: TestAccAWSCodeBuildProject_Source_Auth (30.58s) --- PASS: TestAccAWSCodeBuildProject_Source_GitCloneDepth (32.53s) --- PASS: TestAccAWSCodeBuildProject_Source_InsecureSSL (31.51s) --- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_Bitbucket (32.10s) --- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_GitHub (31.24s) --- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_GitHubEnterprise (41.85s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_Bitbucket (33.70s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_CodeCommit (33.65s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_CodePipeline (33.85s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_GitHubEnterprise (33.55s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_NoSource (33.11s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_NoSourceInvalid (11.74s) --- PASS: TestAccAWSCodeBuildProject_Source_Type_S3 (37.75s) --- PASS: TestAccAWSCodeBuildProject_Tags (42.64s) --- PASS: TestAccAWSCodeBuildProject_VpcConfig (63.50s) --- PASS: TestAccAWSCodeBuildProject_WindowsContainer (33.05s) ```
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated the DiffSuppressFunc
and acceptance testing is still passing:
--- PASS: TestAccAWSCodeBuildProject_Artifacts_EncryptionDisabled (53.64s)
--- PASS: TestAccAWSCodeBuildProject_Artifacts_NamespaceType (57.02s)
--- PASS: TestAccAWSCodeBuildProject_Artifacts_OverrideArtifactName (56.85s)
--- PASS: TestAccAWSCodeBuildProject_Artifacts_Packaging (56.31s)
--- PASS: TestAccAWSCodeBuildProject_Artifacts_Path (61.53s)
--- PASS: TestAccAWSCodeBuildProject_BadgeEnabled (30.06s)
--- PASS: TestAccAWSCodeBuildProject_basic (31.13s)
--- PASS: TestAccAWSCodeBuildProject_BuildTimeout (39.00s)
--- PASS: TestAccAWSCodeBuildProject_Cache (65.22s)
--- PASS: TestAccAWSCodeBuildProject_Description (38.67s)
--- PASS: TestAccAWSCodeBuildProject_EncryptionKey (57.59s)
--- PASS: TestAccAWSCodeBuildProject_Environment_Certificate (39.07s)
--- PASS: TestAccAWSCodeBuildProject_Environment_EnvironmentVariable (41.42s)
--- PASS: TestAccAWSCodeBuildProject_Environment_EnvironmentVariable_Type (38.48s)
--- PASS: TestAccAWSCodeBuildProject_Environment_RegistryCredential (43.88s)
--- PASS: TestAccAWSCodeBuildProject_importBasic (34.06s)
--- PASS: TestAccAWSCodeBuildProject_LogsConfig_CloudWatchLogs (48.99s)
--- PASS: TestAccAWSCodeBuildProject_LogsConfig_S3Logs (75.52s)
--- PASS: TestAccAWSCodeBuildProject_SecondaryArtifacts (38.24s)
--- PASS: TestAccAWSCodeBuildProject_SecondarySources_CodeCommit (33.84s)
--- PASS: TestAccAWSCodeBuildProject_Source_Auth (30.58s)
--- PASS: TestAccAWSCodeBuildProject_Source_GitCloneDepth (32.53s)
--- PASS: TestAccAWSCodeBuildProject_Source_InsecureSSL (31.51s)
--- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_Bitbucket (32.10s)
--- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_GitHub (31.24s)
--- PASS: TestAccAWSCodeBuildProject_Source_ReportBuildStatus_GitHubEnterprise (41.85s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_Bitbucket (33.70s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_CodeCommit (33.65s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_CodePipeline (33.85s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_GitHubEnterprise (33.55s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_NoSource (33.11s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_NoSourceInvalid (11.74s)
--- PASS: TestAccAWSCodeBuildProject_Source_Type_S3 (37.75s)
--- PASS: TestAccAWSCodeBuildProject_Tags (42.64s)
--- PASS: TestAccAWSCodeBuildProject_VpcConfig (63.50s)
--- PASS: TestAccAWSCodeBuildProject_WindowsContainer (33.05s)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍 👍
This has been released in version 2.22.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 for triage. Thanks! |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Community Note
Closes #755
Closes #2050
Closes #6214
Reference: #6427
Closes #7582
Release note for CHANGELOG:
Output from acceptance testing: