Repository navigation
test(node): propagate server-task JoinResult in client_loopback teardown - #814
Conversation
Await the spawned accept-loop task with `?` instead of `let _ =` across the loopback suite so a panic in the background server task fails the test rather than being silently swallowed. After `close()` the accept loop exits cleanly, so this only surfaces genuine panics. Follow-up to the same fix in the two-hop test (#813). Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
There was a problem hiding this comment.
Code Review
This pull request updates multiple test cases in crates/node/tests/client_loopback.rs to propagate errors from the server_task join handle using server_task.await? instead of silently ignoring them with let _ = server_task.await;. This ensures that any server-side panics or errors during test execution are properly caught and reported, improving test reliability. There are no review comments to address, and I have no additional feedback to provide.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
There was a problem hiding this comment.
Pull request overview
This PR tightens the client_loopback integration test suite teardown behavior so that panics in the background server accept-loop task are no longer silently swallowed, aligning the suite with the failure-propagation convention introduced in #813.
Changes:
- Replace
let _ = server_task.await;withserver_task.await?;across theclient_loopbacktests to surfaceJoinError(notably panics) from the spawned server task. - Ensure test failures correctly reflect background-task crashes rather than passing with hidden panics.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Coverage reportTotal: 87.15% (was 87.15%, ● 0.00%) — 28093/32234 lines No coverage data for changed Rust files. History
|
Summary
Follow-up to #813. Across the
client_loopbacksuite, the teardown awaited the spawned accept-loop task withlet _ = server_task.await;, which swallows a panic in the background server task. Switched all sites toserver_task.await?;so a panicked background task fails the test.After
server_ep.close().await, the accept loop exits cleanly (returnsOk(())), so?introduces no false failures — it only surfaces genuine panics. This brings the existing suite in line with the convention adopted in the two-hop test (#813).Verification
cargo fmt -- --check: cleancargo clippy -p decdn-node --tests: no warningscargo nextest run -p decdn-node --test client_loopback: 18/18 pass🤖 Generated with Claude Code