fix(qa-lab): harden telegram qa artifacts

This commit is contained in:
Ayaan Zaidi
2026-04-10 21:33:47 +05:30
parent d69cc5da5c
commit ecb3e0a62d
5 changed files with 122 additions and 11 deletions

View File

@@ -57,6 +57,7 @@ vi.mock("./docker-up.runtime.js", () => ({
}));
import {
__testing,
runQaLabSelfCheckCommand,
runQaDockerBuildImageCommand,
runQaDockerScaffoldCommand,
@@ -185,6 +186,15 @@ describe("qa cli runtime", () => {
});
});
it("rejects output dirs that escape the repo root", () => {
expect(() =>
__testing.resolveRepoRelativeOutputDir("/tmp/openclaw-repo", "../outside"),
).toThrow("--output-dir must stay within the repo root.");
expect(() =>
__testing.resolveRepoRelativeOutputDir("/tmp/openclaw-repo", "/tmp/outside"),
).toThrow("--output-dir must be a relative path inside the repo root.");
});
it("defaults telegram qa runs onto the live provider lane", async () => {
await runQaTelegramCommand({
repoRoot: "/tmp/openclaw-repo",