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 support for breached_password_detection.stage on auth0_attack_protection resource #445

Merged
merged 12 commits into from
Jan 27, 2023
Merged

Add support for breached_password_detection.stage on auth0_attack_protection resource #445

merged 12 commits into from
Jan 27, 2023

Conversation

nialdaly
Copy link
Contributor

@nialdaly nialdaly commented Jan 27, 2023

Summary

This PR aims to close this issue.

@sergiught
Copy link
Contributor

@nialdaly You're a rockstar ⭐ Much appreciated for already trying to contribute this to the repo. Please don't hesitate to ask for support if needed to get this in the right place.

Adding tests and making them pass for terraform will be very similar to how they are done on the Go SDK side: https://github.com/auth0/go-auth0/blob/main/CONTRIBUTING.md (I have on my TODO to update it here as well).

Also make sure to update the examples and to regenerate the docs afterwards with make docs.

@nialdaly nialdaly marked this pull request as ready for review January 27, 2023 12:38
@nialdaly nialdaly requested a review from a team as a code owner January 27, 2023 12:38
@nialdaly
Copy link
Contributor Author

Hey @sergiught thanks for the pointers! I've updated the test recordings, not 100% sure if they are correct.

@nialdaly
Copy link
Contributor Author

When running the tests locally @sergiught I'm getting the following error. I'm not sure if its related to the updated test recording:

=== RUN   TestAccAttackProtectionBreachedPasswordDetection
    resource_auth0_attack_protection_test.go:60: Step 2/4 error: After applying this test step and performing a `terraform refresh`, the plan was not empty.
        stdout
        
        
        Terraform used the selected providers to generate the following execution
        plan. Resource actions are indicated with the following symbols:
          ~ update in-place
        
        Terraform will perform the following actions:
        
          # auth0_attack_protection.my_protection will be updated in-place
          ~ resource "auth0_attack_protection" "my_protection" {
                id = "terraform-20230127163011958200000006"
        
              ~ breached_password_detection {
                  ~ shields                      = [
                      + "admin_notification",
                      + "block",
                    ]
                    # (3 unchanged attributes hidden)
        
                    # (1 unchanged block hidden)
                }
        
        
                # (2 unchanged blocks hidden)
            }
        
        Plan: 0 to add, 1 to change, 0 to destroy.
--- FAIL: TestAccAttackProtectionBreachedPasswordDetection (1.20s)

Copy link
Contributor

@sergiught sergiught left a comment

Choose a reason for hiding this comment

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

Great work @nialdaly 💪🏻 Fantastic contribution!

@sergiught sergiught changed the title breached_password_detection.stage support Add support for breached_password_detection.stage on auth0_attack_protection resource Jan 27, 2023
@sergiught sergiught merged commit d28ce62 into auth0:main Jan 27, 2023
@nialdaly
Copy link
Contributor Author

Thanks for all your help! @sergiught

@nialdaly nialdaly deleted the breached-password-detection-stage branch January 27, 2023 17:38
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