Files
OmniRoute/scripts/devin-bridge/test-contract
Lucas Israel 2a94cbfe14 feat(executors): add isolated Claude Code bridge over Devin ACP (#8914)
Validated in post-merge-train sweep (boards clean on release/v3.8.50 tip)
2026-08-06 11:08:37 -03:00

25 lines
1.0 KiB
Bash
Executable File

#!/usr/bin/env bash
set -euo pipefail
source "$(dirname "$0")/common"
bridge_prepare_sandbox
rm -f "$BRIDGE_SANDBOX/evidence/mock-acp.jsonl"
"$(dirname "$0")/verify-anthropic-isolation" --static
docker compose -f "$BRIDGE_COMPOSE" --profile offline down --remove-orphans
docker compose -f "$BRIDGE_COMPOSE" --profile offline up --abort-on-container-exit \
--exit-code-from contract contract
node -e '
const fs = require("node:fs");
const rows = fs.readFileSync(process.argv[1], "utf8").trim().split("\n").map(JSON.parse);
const repairRows = rows.filter((row) => row.scenario === "narrative-repair");
if (
rows.length !== 7 ||
rows.some((row) => row.provider !== "devin-cli-agentic") ||
repairRows.length !== 2 ||
repairRows[0].stage !== "initial" ||
repairRows[1].stage !== "repair"
) {
throw new Error("wire contract observed a missing or non-Devin provider");
}
' "$BRIDGE_SANDBOX/evidence/mock-acp.jsonl"
printf 'PASS: bridge wire contract suite completed without provider fallback\n'