Garry's Opinionated OpenClaw/Hermes Agent Brain
TypeScript
test: the valid-time minimum host version is the release whose CHANGELOG adds get_page as_of
garrytan339aeb36750c
diff --git a/test/valid-time-gbra217.test.ts b/test/valid-time-gbra217.test.tsindex bec26b6a60..414bdd8b58 100644--- a/test/valid-time-gbra217.test.ts+++ b/test/valid-time-gbra217.test.ts@@ -14,6 +14,8 @@* longer writes (an unmarked pre-upgrade page) or volume (500 versions).*/import { afterAll, beforeAll, describe, expect, test } from 'bun:test';+import { readFileSync } from 'node:fs';+import { join } from 'node:path';import { PGLiteEngine } from '../src/core/pglite-engine.ts';import { PostgresEngine } from '../src/core/postgres-engine.ts';import type { BrainEngine } from '../src/core/engine.ts';@@ -83,6 +85,13 @@ describe('valid-time normaliser and verdict (pure)', () => {expect(() => assertValidTimeEcho({}, plain, { client: 'x', host: null })).not.toThrow();});+ test('B4: the minimum host version is the release whose CHANGELOG entry adds get_page as_of', () => {+ const sections = readFileSync(join(import.meta.dir, '..', 'CHANGELOG.md'), 'utf8').split(/^## \[/m).slice(1);+ const adding = sections.filter((s) => s.includes('get_page {slug, as_of')).map((s) => s.slice(0, s.indexOf(']')));+ expect(adding.length).toBeGreaterThan(0);+ expect(VALID_TIME_MIN_HOST_VERSION).toBe(adding[adding.length - 1]);+ });+test('B2b: CLI rendering puts the header on stderr, no document under another status, exit 15', () => {const writes: string[] = [];const orig = process.stderr.write.bind(process.stderr);