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

tech-debt/waf_xss_match_set: update test configuration params, disappears methods, and enumerated vals #14962

Merged
merged 2 commits into from
Sep 2, 2020

Conversation

anGie44
Copy link
Contributor

@anGie44 anGie44 commented Sep 1, 2020

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 #14957
Relates #14601

Release note for CHANGELOG:

tech-debt/waf_xss_match_set: update configuration params, disappears methods and enumerated vals
tech-debt/waf_regional_xss_match_set: update configuration params, disappears methods and enumerated vals

Output from acceptance testing:

--- PASS: TestAccAWSWafRegionalXssMatchSet_changeTuples (42.65s)
--- PASS: TestAccAWSWafXssMatchSet_changeTuples (59.45s)

--- PASS: TestAccAWSWafRegionalXssMatchSet_basic (27.22s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_disappears (27.42s)
--- PASS: TestAccAWSWafXssMatchSet_noTuples (34.67s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_noTuples (36.26s)
--- PASS: TestAccAWSWafXssMatchSet_disappears (37.10s)
--- PASS: TestAccAWSWafXssMatchSet_basic (45.68s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_changeNameForceNew (47.83s)
--- PASS: TestAccAWSWafXssMatchSet_changeNameForceNew (54.72s)

@anGie44 anGie44 added the technical-debt Addresses areas of the codebase that need refactoring or redesign. label Sep 1, 2020
@ghost ghost added size/L Managed by automation to categorize the size of a PR. service/waf Issues and PRs that pertain to the waf service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. labels Sep 1, 2020
@anGie44 anGie44 marked this pull request as ready for review September 1, 2020 21:16
@anGie44 anGie44 requested a review from a team September 1, 2020 21:16
@bflad bflad self-assigned this Sep 2, 2020
Copy link
Contributor

@bflad bflad left a comment

Choose a reason for hiding this comment

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

Looks good, just one note for consideration 🚀

Output from acceptance testing:

--- PASS: TestAccAWSWafRegionalXssMatchSet_noTuples (22.19s)
--- PASS: TestAccAWSWafXssMatchSet_disappears (26.10s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_basic (26.89s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_disappears (28.46s)
--- PASS: TestAccAWSWafXssMatchSet_noTuples (28.76s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_changeTuples (39.56s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_changeNameForceNew (43.08s)
--- PASS: TestAccAWSWafXssMatchSet_basic (44.87s)
--- PASS: TestAccAWSWafXssMatchSet_changeTuples (48.84s)
--- PASS: TestAccAWSWafXssMatchSet_changeNameForceNew (67.30s)

@@ -197,47 +197,6 @@ func TestAccAWSWafXssMatchSet_noTuples(t *testing.T) {
})
}

func testAccCheckAWSWafXssMatchSetDisappears(v *waf.XssMatchSet) resource.TestCheckFunc {
Copy link
Contributor

Choose a reason for hiding this comment

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

😍

aws/structure.go Outdated
if fm.Type != nil {
m["type"] = *fm.Type
}
m["data"] = aws.StringValue(fm.Data)
Copy link
Contributor

Choose a reason for hiding this comment

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

Just noting here that sometimes the nil checking is desirable to prevent unexpected difference output (null versus "" differences between configuration block updates that show as adding and removing the "same" block in Terraform plan output). I'm not sure if that is the case here, but usually the nil checking is more deterministic in behavior and what we will likely be doing in the future with code generation.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ooo that's a good point, i'll move this back as it was 👍

@anGie44 anGie44 changed the title tech-debt/waf_xss_match_set: update configuration params, disappears methods, and enumerated vals tech-debt/waf_xss_match_set: update test configuration params, disappears methods, and enumerated vals Sep 2, 2020
@anGie44
Copy link
Contributor Author

anGie44 commented Sep 2, 2020

Reverted to nil check method in 7ed2b1d

Output of acceptance tests:

--- PASS: TestAccAWSWafXssMatchSet_noTuples (13.95s)
--- PASS: TestAccAWSWafXssMatchSet_disappears (16.74s)
--- PASS: TestAccAWSWafXssMatchSet_basic (18.13s)
--- PASS: TestAccAWSWafXssMatchSet_changeTuples (27.63s)
--- PASS: TestAccAWSWafXssMatchSet_changeNameForceNew (30.29s)

--- PASS: TestAccAWSWafRegionalXssMatchSet_noTuples (16.33s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_basic (23.37s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_disappears (23.95s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_changeTuples (35.79s)
--- PASS: TestAccAWSWafRegionalXssMatchSet_changeNameForceNew (38.39s)

@anGie44 anGie44 added this to the v3.5.0 milestone Sep 2, 2020
@anGie44 anGie44 merged commit 8bc472a into master Sep 2, 2020
@anGie44 anGie44 deleted the td-waf-change-tuples-tests branch September 2, 2020 17:27
@ghost
Copy link

ghost commented Sep 3, 2020

This has been released in version 3.5.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!

@ghost
Copy link

ghost commented Oct 3, 2020

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!

@ghost ghost locked as resolved and limited conversation to collaborators Oct 3, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
service/waf Issues and PRs that pertain to the waf service. size/L Managed by automation to categorize the size of a PR. technical-debt Addresses areas of the codebase that need refactoring or redesign. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants