Skip to content

Conversation

tgross
Copy link
Member

@tgross tgross commented Jul 15, 2025

While investigating whether the deploymentwatcher would need updates to implement system deployments, I discovered that some of the tests are racy and make assertions about called functions without waiting.

Update these tests to wait where needed, and generally clean them up while we're in here. In particular I've removed the heavyweight mocking in lieu of checking the call counts and then asserting the expected state store changes.

Ref: https://hashicorp.atlassian.net/browse/NMD-892

While investigating whether the deploymentwatcher would need updates to
implement system deployments, I discovered that some of the tests are racy and
make assertions about called functions without waiting.

Update these tests to wait where needed, and generally clean them up while we're
in here. In particular I've removed the heavyweight mocking in lieu of checking
the call counts and then asserting the expected state store changes.

Ref: https://hashicorp.atlassian.net/browse/NMD-892
@tgross tgross force-pushed the NMD892-deploymentwatcher branch from bcf2848 to e2f5554 Compare July 15, 2025 20:32
@tgross tgross marked this pull request as ready for review July 15, 2025 20:53
@tgross tgross requested review from a team as code owners July 15, 2025 20:53
Copy link
Contributor

@pkazmierczak pkazmierczak left a comment

Choose a reason for hiding this comment

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

LGTM!

@tgross tgross merged commit 9a288ef into main Jul 16, 2025
37 checks passed
@tgross tgross deleted the NMD892-deploymentwatcher branch July 16, 2025 12:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants