Public: anyone can read this; the crew can change it.

Full suite red: 2 files in check run 01m7gm2t9vtkyd437k7afwts8a #13742

Merged opened this in answer to

Check · Review · Land · Live done — Landed and live in production.

Merged

torque/forge:torque/13740-full-suite-red-2-files-in-check-run-01m7 → main 1 commit fork

  • Merged. torque/13740-full-suite-red-2-files-in-check-run-01m7 was merged into main as 1e98e4f.

Review

Sign in to review this change.
2 files changed +15 −11
test/engine-split.test.ts +11 −7
@@ -273,12 +273,13 @@ describe("the engine thread", () => {
273273 extra: [WRITER],
274274 restartMinMs: 50,
275275 // Longer than a boot: an engine is silent until it is up, and one ended before its first row
276 // is life 1 again and hangs again. A boot takes about 2.5 s on a loaded box, so 1.5 s looped.
277 stallMs: 5_000,
276 // is life 1 again and hangs again. A boot takes about 2.5 s on a loaded box (over 5 s under
277 // the full suite, which looped at 5 s), so the stall is well past that.
278 stallMs: 12_000,
278279 });
279280 engines.push(engine);
280281 // Stuck inside a write transaction from its first second, never ready: the watch ends it.
281 await until(() => engine.restarts() === 1, 20_000);
282 await until(() => engine.restarts() >= 1, 40_000);
282283 await engine.ready();
283284 expect(
284285 serve.db
@@ -288,7 +289,7 @@ describe("the engine thread", () => {
288289 >("SELECT COUNT(*) AS n FROM engine_scratch WHERE n = -99")
289290 .get()?.n,
290291 ).toBe(0);
291 }, 30_000);
292 }, 60_000);
292293 });
293294
294295 describe("an engine that cannot be kept", () => {
@@ -375,7 +376,8 @@ describe("a run is started once", () => {
375376 process.env["ENGINE_TEST"] = "claimer";
376377 const engine = startEngine(serve.config, tail, { extra: [WRITER] });
377378 engines.push(engine);
378 // This thread takes its first few before the engine is up (it may be quicker than this thread once it is), then they compete.
379 // This thread takes its first few before the engine is up (it may be quicker than this thread
380 // once it is), then they compete.
379381 let mine = 0;
380382 for (const id of ids.slice(0, 300)) if (claimRun(serve.db, id) !== undefined) mine++;
381383 await engine.ready();
@@ -383,7 +385,8 @@ describe("a run is started once", () => {
383385 if (claimRun(serve.db, id) !== undefined) mine++;
384386 if (mine % 10 === 0) await Bun.sleep(0);
385387 }
386 // The engine counts a claim in a statement of its own, just after the claim: wait for the books to close.
388 // The engine counts a claim in a statement of its own, just after the claim: wait for the books
389 // to close.
387390 const theirsNow = (): number =>
388391 serve.db.query<{ n: number }, []>("SELECT COUNT(*) AS n FROM engine_scratch WHERE n = -1").get()?.n ?? 0;
389392 await until(() => mine + theirsNow() >= 3000);
@@ -445,7 +448,8 @@ describe("a stream that resumes while the engine writes", () => {
445448 // ...in the outbox's order...
446449 const seqs = got.map((id) => seqOf.get(id)!);
447450 for (let i = 1; i < seqs.length; i++) expect(seqs[i]).toBeGreaterThan(seqs[i - 1]!);
448 // ...and none missing between its first and its last frame (the replay is the newest 200 after the cursor).
451 // ...and none missing between its first and its last frame (the replay is the newest 200
452 // after the cursor).
449453 const first = seqs[0]!;
450454 const last = seqs[seqs.length - 1]!;
451455 expect(got).toEqual(kindsOf().filter((e) => e.seq >= first && e.seq <= last).map((e) => e.id));
test/tui-make-it-yours.test.ts +4 −4
@@ -115,10 +115,10 @@ test("esc copies nothing", async () => {
115115 });
116116
117117 test("a sixth copy in a day is refused in MCP's words, and nothing is made", async () => {
118 for (let i = 0; i < COPIES_PER_DAY; i++) {
119 const r = await makeItYours(forge, carol, await original(), { dryRun: false });
120 if (!r.ok) throw new Error(JSON.stringify(r.error));
121 }
118 // The day's count is the fork_made ledger: fill it, rather than make five real copies (2 s a
119 // test).
120 for (let i = 0; i < COPIES_PER_DAY; i++)
121 forge.db.query("INSERT INTO fork_made (owner_id, made_at) VALUES (?1, ?2)").run(carol.id, new Date().toISOString());
122122 const repo = await original();
123123 const h = await open(carol, repo);
124124 await h.press("Y");

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs