Skip to content

Commit 59ed09f

Browse files
mchwangclaude
andcommitted
Comment fixes: what main's check was; what removeByName reads (#189)
Review round 46. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 6fe98b9 commit 59ed09f

2 files changed

Lines changed: 6 additions & 4 deletions

File tree

‎test/agent-container.test.ts‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2375,8 +2375,9 @@ describe('real Docker agent isolation', () => {
23752375
const data = fixture(), runnerOwner = randomBytes(16).toString('hex');
23762376
const owner = { runnerOwner, attemptId: 'unsettled-allocation', allocationId: randomUUID() };
23772377
// Another runner's objects, so no sweep of this run finds them: removed by allocation when the test finishes (#189).
2378-
// After a pass, nothing of the allocation may be left once that sweep has run, as on main; this check, registered
2379-
// first, runs after the sweep (Vitest runs onTestFinished hooks in reverse order).
2378+
// After a pass, a listing that fails fails the test, as on main, and now nothing of the allocation may be left once
2379+
// that sweep has run either; this check, registered first, runs after the sweep (Vitest runs onTestFinished hooks
2380+
// in reverse order).
23802381
let passed = false;
23812382
onTestFinished(() => { if (passed) expect(byAllocation(owner.allocationId)).toEqual([]); }, 2 * 60_000);
23822383
sweepWhenFinished('io.codeboost.allocation', owner.allocationId);

‎test/docker-sweep.test.ts‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,9 @@ import type * as Sweep from './fixtures/docker-sweep.ts';
99
// The test sweep's and `removeByName`'s handling of answers they cannot use (#189), each test with its own fake
1010
// `docker`, described beside it. The sweep reads only stdout, the exit status, whether a signal killed the call and
1111
// whether it could start, and stderr to report a failure, and, for its read of holders, to tell one gone since the
12-
// listing ("No such container") from a failure; `removeByName` also reads an inspect's stderr to tell a missing object
13-
// from a failure. Against the daemon, agent-container's holder test covers the sweep and removeByName's
12+
// listing ("No such container") from a failure. `removeByName` reads the same, and also an inspect's stdout (the ID and
13+
// name) and its stderr, to tell a missing object from a failure, and a network removal's stderr, to tell a network
14+
// gone since its inspect. Against the daemon, agent-container's holder test covers the sweep and removeByName's
1415
// removal, its silence on a missing name, and its refusal of an object found by an ID prefix.
1516
const roots: string[] = [];
1617
afterEach(() => {

0 commit comments

Comments
 (0)