refactor(contest): extract run_container_with_console helper into test_utils - #3693
Open
aniketch07 wants to merge 1 commit into
Open
refactor(contest): extract run_container_with_console helper into test_utils#3693aniketch07 wants to merge 1 commit into
aniketch07 wants to merge 1 commit into
Conversation
aniketch07
force-pushed
the
issues/3529
branch
from
August 16, 2026 08:31
91518cf to
fbe0af5
Compare
…t_utils Signed-off-by: aniketch07 <caniket1307@gmail.com>
aniketch07
force-pushed
the
issues/3529
branch
from
August 20, 2026 15:15
fbe0af5 to
60d8c33
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #3529
Extracts the detached-run + console-socket handling (
run -d --console-socket) out ofCrTestContext::startinto a reusable global helperrun_container_with_consoleintests/contest/contest/src/utils/test_utils.rs, as agreed in the review of #3493.pub fn run_container_with_console(runtime_path, bundle_path, container_id)inutils/test_utils.rsCrTestContext::startnow delegates to it (removes the TODO referencing [Refactor]: Extract Checkpoint/Restore terminal spawn logic into test_utils.rs #3529)utils/mod.rs;handle_console_socketre-export dropped (fn stays pub intest_utils)console.sockbefore binding, mirroring the restore pathValidation:
cargo check -p contest --all-targets✅cargo clippy -p contest --all-targets --all-features -- -D warnings✅cargo fmt -p contest -- --check✅Note: local
cargo test --no-runlink needslibseccomp(missing in this WSL env); code compiles clean and CI runners have it.cc maintainers — no rush.