fix: harden release gate and page delivery
Memind CI / Test, build, and release guards (push) Failing after 12m3s
Memind CI / Test, build, and release guards (push) Failing after 12m3s
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
#!/usr/bin/env node
|
||||
import path from 'node:path';
|
||||
|
||||
import { loadScenarioCatalog } from '../release-gate/catalog.mjs';
|
||||
import { loadActiveRegressionCorpus } from '../release-gate/regression-corpus.mjs';
|
||||
import { runCommand } from '../release-gate/runner.mjs';
|
||||
|
||||
const root = path.resolve(new URL('..', import.meta.url).pathname);
|
||||
const catalog = await loadScenarioCatalog({ root });
|
||||
const corpus = await loadActiveRegressionCorpus({ root, catalog });
|
||||
|
||||
if (corpus.status !== 'ready') {
|
||||
console.error(
|
||||
`COMP-09 blocked: regression corpus is ${corpus.status}; `
|
||||
+ `${corpus.errors.join('; ') || 'no active privacy-reviewed manifest'}`,
|
||||
);
|
||||
process.exit(1);
|
||||
}
|
||||
|
||||
for (const fixture of corpus.fixtures) {
|
||||
const [command, ...args] = fixture.automation.command;
|
||||
const result = await runCommand(command, args, {
|
||||
cwd: root,
|
||||
timeoutMs: Number(process.env.RELEASE_GATE_CORPUS_CASE_TIMEOUT_MS ?? 60_000),
|
||||
});
|
||||
if (result.code !== 0 || result.timedOut) {
|
||||
console.error(`COMP-09 fixture failed: ${fixture.id}`);
|
||||
console.error(result.stderr || result.stdout);
|
||||
process.exit(1);
|
||||
}
|
||||
console.log(`PASS ${fixture.id} ${fixture.scenario_ids.join(',')}`);
|
||||
}
|
||||
|
||||
console.log(`PASS COMP-09 fixtures=${corpus.fixtures.length} production_connected=false`);
|
||||
Reference in New Issue
Block a user