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

DT-1182: Fix issue where integration tests would delete the jade service account #1897

Merged
merged 1 commit into from
Jan 30, 2025

Conversation

pshapiro4broad
Copy link
Member

@pshapiro4broad pshapiro4broad commented Jan 29, 2025

Jira ticket: https://broadworkbench.atlassian.net/browse/DT-1182

Addresses

Fix issue where an empty service account email would result in the SA being deleted when running integration tests

Summary of changes

The previous change replaced ApplicationConfiguration with IntegrationTestConfiguration, so integration tests would have a more limited application context (e.g., not including a database connection). To satisfy the tdrServiceAccountEmail injection I added a stub method to return an empty string, which seemed to work fine (as this value isn't needed for tests to work correctly). However, it's used during teardown to prevent the test from deleting a service account. This use wasn't immediately apparent so the change was merged.

The fixed code uses the ApplicationConfiguration implementation to return the service account email.

Testing Strategy

After integration tests run, verify that the service account is still present.

… being _deleted_ by running integration tests
@pshapiro4broad pshapiro4broad requested a review from a team as a code owner January 29, 2025 21:27
@pshapiro4broad pshapiro4broad requested review from rushtong and rjohanek and removed request for a team January 29, 2025 21:27
Copy link
Contributor

@fboulnois fboulnois left a comment

Choose a reason for hiding this comment

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

👍

@rjohanek rjohanek merged commit cf5ac57 into develop Jan 30, 2025
14 checks passed
@rjohanek rjohanek deleted the ps/integration-test-fix branch January 30, 2025 14:57
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.

3 participants