-
Notifications
You must be signed in to change notification settings - Fork 389
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
provider: add "validate" option that can disable validation #474
Conversation
+1 on this, we have a use case where we conditionally create DD resources. Right now even when no DD resources are created we need to provide the provider with valid credentials so this would help us improve that! |
Fixing the build, forgot to close a |
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.
Thanks @bendrucker for working on this! The code looks good. I left just one inline comment. Looks like there are also some conflicts based on some recent changes. Would you be able to address those?
cd71bc3
to
031f0af
Compare
031f0af
to
a44094f
Compare
Changes:
Notes:
|
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.
Left a couple last comments. (They're all really small)
Thanks again for the work here, and the docs 🙇!
Changes made! |
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.
Thanks for all the work here! Merging!
This allows users to disable credential validation by setting
validate = false
in the provider configuration.Use Case
I recently wrote some tests for a set of complex modules that abstract details of Datadog resources, e.g. monitors and synthetic tests. While I might E2E test these configurations in a dedicated sandbox account, initially I wanted to write tests that assert some of the contents of:
The resulting JSON document has
planned_resources
andchanged_resources
. There's no existing state so I only care about theplanned_resources
. Currently these tests require valid credentials but they would pass just the same with mock credentials if validation could be disabled.Closes #368