fe23ffa100
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
23 lines
1004 B
JavaScript
23 lines
1004 B
JavaScript
#!/usr/bin/env node
|
|
// Scripted half of the F3 manual smoke (docs/MANUAL-SMOKE-F3.md). Drives the
|
|
// REAL LiveTurn module against the local Claude Code login. Not run in CI.
|
|
import { runEditTurn } from "../out/liveTurn.mjs";
|
|
|
|
const instruction = process.argv[2] ?? "Replace this sentence with exactly: The smoke test passed.";
|
|
const text = process.argv[3] ?? "This sentence is the smoke-test input.";
|
|
|
|
console.log(`instruction: ${instruction}`);
|
|
console.log(`text: ${text}`);
|
|
try {
|
|
const t0 = Date.now();
|
|
const result = await runEditTurn(instruction, text);
|
|
console.log(`replacement: ${JSON.stringify(result.replacement)}`);
|
|
console.log(`model: ${result.model}`);
|
|
console.log(`sessionId: ${result.sessionId}`);
|
|
console.log(`elapsed: ${((Date.now() - t0) / 1000).toFixed(1)}s`);
|
|
process.exit(0);
|
|
} catch (err) {
|
|
console.error(`live turn failed (expected when Claude Code is absent/signed out): ${err instanceof Error ? err.message : String(err)}`);
|
|
process.exit(1);
|
|
}
|