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

Adding Retry to Escalation Policy Delete and Trim to User.name #309

Merged
merged 1 commit into from
Mar 9, 2021

Conversation

stmcallister
Copy link
Contributor

Adding retry logic to resource_pagerduty_escalation_policy delete function to help give dependent objects time to delete.

Test results:

TF_ACC=1 go test -run "TestAccPagerDutyEscalationPolicy" ./pagerduty -v -timeout 120m
=== RUN   TestAccPagerDutyEscalationPolicy_import
--- PASS: TestAccPagerDutyEscalationPolicy_import (7.24s)
=== RUN   TestAccPagerDutyEscalationPolicy_Basic
--- PASS: TestAccPagerDutyEscalationPolicy_Basic (8.76s)
=== RUN   TestAccPagerDutyEscalationPolicyWithTeams_Basic
--- PASS: TestAccPagerDutyEscalationPolicyWithTeams_Basic (9.01s)
PASS
ok  	github.com/terraform-providers/terraform-provider-pagerduty/pagerduty	36.389s

Adding a trim on the resource_pagerduty_user.name field so that leading and trailing spaces don't trigger diffs.

Test results:

TF_ACC=1 go test -run "TestAccPagerDutyUser" ./pagerduty -v -timeout 120m
=== RUN   TestAccPagerDutyUserContactMethod_import
--- PASS: TestAccPagerDutyUserContactMethod_import (6.46s)
=== RUN   TestAccPagerDutyUserNotificationRule_import
--- PASS: TestAccPagerDutyUserNotificationRule_import (8.36s)
=== RUN   TestAccPagerDutyUser_import
--- PASS: TestAccPagerDutyUser_import (4.96s)
=== RUN   TestAccPagerDutyUserContactMethodEmail_Basic
--- PASS: TestAccPagerDutyUserContactMethodEmail_Basic (7.98s)
=== RUN   TestAccPagerDutyUserContactMethodPhone_Basic
--- PASS: TestAccPagerDutyUserContactMethodPhone_Basic (8.26s)
=== RUN   TestAccPagerDutyUserContactMethodSMS_Basic
--- PASS: TestAccPagerDutyUserContactMethodSMS_Basic (9.51s)
=== RUN   TestAccPagerDutyUserNotificationRuleContactMethod_Basic
--- PASS: TestAccPagerDutyUserNotificationRuleContactMethod_Basic (12.28s)
=== RUN   TestAccPagerDutyUser_Basic
--- PASS: TestAccPagerDutyUser_Basic (7.00s)
=== RUN   TestAccPagerDutyUserWithTeams_Basic
--- PASS: TestAccPagerDutyUserWithTeams_Basic (11.54s)
PASS
ok  	github.com/terraform-providers/terraform-provider-pagerduty/pagerduty	87.708s

Copy link
Collaborator

@heimweh heimweh left a comment

Choose a reason for hiding this comment

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

Nice! 🙂 👌

@stmcallister stmcallister merged commit 434f3dd into PagerDuty:master Mar 9, 2021
@stmcallister stmcallister deleted the retry-ep-delete branch March 9, 2021 18:54
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