feat: add tui recovery state machine

This commit is contained in:
chungyeong
2026-05-14 00:14:27 +09:00
parent ef4c56e6b0
commit e5020a59f0
15 changed files with 1414 additions and 97 deletions

View File

@@ -50,6 +50,26 @@ describe("config loader", () => {
});
expect(config.backends).toContainEqual({ id: "fake", enabled: true });
expect(config.SESSION_MAX_HUNG_MS).toBe(20 * 60 * 1000);
});
it("loads configurable session hung timeout", () => {
const root = mkdtempSync(join(tmpdir(), "devflow-config-"));
const workspace = join(root, "workspace");
mkdirSync(workspace);
const config = loadConfigFromSources({
cwd: root,
env: {
DATABASE_URL: "postgres://devflow:devflow@localhost:5432/devflow",
WORKSPACE_ROOT: workspace,
LOG_LEVEL: "info",
TEMPORAL_ADDRESS: "localhost:7233",
SESSION_MAX_HUNG_MS: "2500",
},
});
expect(config.SESSION_MAX_HUNG_MS).toBe(2500);
});
it("resolves backend binaries from PATH during config load", () => {