Skip to content

Garry's Opinionated OpenClaw/Hermes Agent Brain

TypeScript

test(#6961): the postgres-unit-arms suite pins both weight files to listed arms (replaces the branch-only pregate lane)

garrytanb656d65dd2e5
diff --git a/.gstack/pregate.json b/.gstack/pregate.json
index 4fa419233c..4e0b3706a6 100644
--- a/.gstack/pregate.json
+++ b/.gstack/pregate.json
@@ -66,9 +66,6 @@
"scripts/ubicloud/*.sh": [
"test/scripts/awk-portability.test.ts"
],
- "scripts/postgres-arm-weights-postgres-only.json": [
- "test/scripts/postgres-unit-arms.test.ts"
- ],
"scripts/*-weights.metadata.json": [
"test/scripts/mine-shard-weights.test.ts"
],
diff --git a/scripts/structural-suites.tsv b/scripts/structural-suites.tsv
index 0f4f5eb70a..90b3ca1723 100644
--- a/scripts/structural-suites.tsv
+++ b/scripts/structural-suites.tsv
@@ -339,7 +339,7 @@ test/scripts/nightly-issue.test.ts nightly-watch incidents 9 readFileSync
test/scripts/nightly-issue.test.ts nightly-watch routing and guard 9 readFileSync
test/scripts/nightly-issue.test.ts operator messages carry docs anchors that resolve 1 readFileSync
test/scripts/postgres-lane-coverage.test.ts check-postgres-lane-coverage.ts 9 readFileSync
-test/scripts/postgres-unit-arms.test.ts postgres-unit-arms list 13 readFileSync
+test/scripts/postgres-unit-arms.test.ts postgres-unit-arms list 14 readFileSync
test/scripts/promote-stable.test.ts promote-stable.yml 2 readFileSync
test/scripts/regen-all.test.ts regen:all 5 readFileSync
test/scripts/require-executed-tests.test.ts require-executed-tests 9 readFileSync
diff --git a/test/scripts/postgres-unit-arms.test.ts b/test/scripts/postgres-unit-arms.test.ts
index 201fbadcf5..bb5ac5273b 100644
--- a/test/scripts/postgres-unit-arms.test.ts
+++ b/test/scripts/postgres-unit-arms.test.ts
@@ -26,6 +26,13 @@ describe('postgres-unit-arms list', () => {
expect(list.files.length).toBeGreaterThan(50);
});
+ test('every weight in both committed weight files names a listed arm file', () => {
+ const listed = new Set(readArmsList(REPO).files);
+ for (const file of ['scripts/postgres-arm-weights.json', 'scripts/postgres-arm-weights-postgres-only.json']) {
+ expect(Object.keys(JSON.parse(readFileSync(join(REPO, file), 'utf8'))).filter(name => !listed.has(name))).toEqual([]);
+ }
+ });
+
test('the two CI shards cover every listed file exactly once', () => {
const all = cli('list').stdout.trim().split('\n');
const shards = [1, 2].map(n => cli('shard', String(n), '2').stdout.trim().split('\n'));