Skip to content

EEBus: fix test cleanup regression breaking TestShipPairing - #31617

Merged
andig merged 1 commit into
masterfrom
fix/eebus-gridguard-test-cleanup
Jul 9, 2026
Merged

EEBus: fix test cleanup regression breaking TestShipPairing#31617
andig merged 1 commit into
masterfrom
fix/eebus-gridguard-test-cleanup

Conversation

@andig

@andig andig commented Jul 9, 2026

Copy link
Copy Markdown
Member

TestControlBoxGridGuardHeartbeat (#31568) never shuts down its server.Instance() or controlbox, relying only on the next test in the package to tear down a leftover instance and on async context cancellation for the controlbox. That was harmless while it was the last test in the package, but it now runs before TestShipPairing (alphabetical file order: cs_test.go, gridguard_test.go, pairing_test.go) — so TestShipPairing can start while the GridGuard test's server/controlbox is still shutting down.

This explains the "paired device not routed to consumer" CI failures on #31570: they started right after a "merge master" commit pulled in #31568, and master itself has been consistently green (nothing else runs after TestControlBoxGridGuardHeartbeat there).

  • Shut down the GridGuard test's server and controlbox explicitly before it returns, instead of leaving cleanup to chance.

🤖 Generated with Claude Code

TestControlBoxGridGuardHeartbeat (PR #31568) never shuts down its
server.Instance() or controlbox, relying only on the next test in the
package to tear down a leftover instance and on async context
cancellation for the controlbox. That was harmless while it was the
last test in the package, but PR #31568 landed it before
TestShipPairing (alphabetical file order: cs_test.go,
gridguard_test.go, pairing_test.go), and TestShipPairing then starts
while the GridGuard test's server/controlbox may still be shutting
down - explaining the "paired device not routed to consumer" CI
failures on PR #31570, which correlate exactly with a "merge master"
commit that pulled in PR #31568.
@andig andig added the bug Something isn't working label Jul 9, 2026

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@andig
andig enabled auto-merge (squash) July 9, 2026 11:03
@andig
andig merged commit 2266228 into master Jul 9, 2026
9 checks passed
@andig
andig deleted the fix/eebus-gridguard-test-cleanup branch July 9, 2026 11:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant