fix(release): withhold unqualified CV review and record gates

This commit is contained in:
cesnimda
2026-10-08 18:40:07 +02:00
parent 9c91575079
commit fe045b9e01
11 changed files with 544 additions and 5 deletions
+22 -1
View File
@@ -6,12 +6,14 @@ import path from "node:path";
// Separate real-HTTP contract suite. Neither process uses the normal browser-suite ports.
const apiUrl = "http://127.0.0.1:15313";
const providerUrl = "http://127.0.0.1:18133";
const productionApiUrl = "http://127.0.0.1:15314";
const dataRoot = process.env.CV_AI_READINESS_DATA_ROOT ??= fs.mkdtempSync(path.join(os.tmpdir(), "jobtracker-cv-ai-readiness-"));
process.env.CV_AI_READINESS_API_URL = apiUrl;
process.env.CV_AI_READINESS_PROVIDER_URL = providerUrl;
process.env.CV_AI_READINESS_PRODUCTION_API_URL = productionApiUrl;
const quote = (value: string) => `"${value.replaceAll('"', '\\"')}"`;
export default defineConfig({
const config = defineConfig({
testDir: "./ai-tests",
testMatch: "cv-ai-readiness.spec.ts",
workers: 1,
@@ -61,3 +63,22 @@ export default defineConfig({
},
],
});
const webServers = Array.isArray(config.webServer) ? config.webServer : [config.webServer!];
const backend = webServers[1];
export default defineConfig({
...config,
webServer: [...webServers, {
...backend,
// Launch settings otherwise override the Production environment with Development.
command: backend.command.replace(" run ", " run --no-launch-profile ").replace(apiUrl, productionApiUrl),
url: `${productionApiUrl}/ready`,
env: {
...backend.env,
ASPNETCORE_ENVIRONMENT: "Production",
App__PublicBaseUrl: productionApiUrl.replace("http:", "https:"),
Data__Root: path.join(dataRoot, "production"),
ConnectionStrings__JobTracker: `Data Source=${path.join(dataRoot, "production", "readiness.sqlite")}`,
},
}],
});