Keep webpage maintenance dates out of ARR financial cutoffs

This commit is contained in:
2026-11-01 00:06:41 +08:00
parent 5b31fa5b77
commit ea31287924
5 changed files with 137 additions and 23 deletions
+1 -1
View File
@@ -184,7 +184,7 @@ async function main() {
const research = await researchResponse.json();
assert.equal(research.companies.length, 1199);
assert.equal(research.categories.length, 11);
assert.equal(research.evidence.length, 4667);
assert.equal(research.evidence.length, 4673);
assert.equal(research.observations.length, 453);
assert.equal((await request("/api/research/ai-companies", { method: "POST", headers })).status, 405);
const researchPage = await request("/docs/other-research/ai-company-research/overview", { headers });
+5 -4
View File
@@ -124,7 +124,7 @@ test("research revisions share the authentication database and preserve replay l
assert.equal(consumeCode(config, "invalid"), "limited");
const initial = readResearchSnapshot();
assert.equal(initial.companies.length, 1199);
assert.equal(initial.evidence.length, 4667);
assert.equal(initial.evidence.length, 4673);
assert.equal(initial.observations.length, 453);
const businessReviews = initial.reviews.filter((review) => review.type === businessModelReviewType);
assert.equal(businessReviews.length, 4);
@@ -169,8 +169,8 @@ test("research validation rejects broken evidence and unsafe source links", () =
test("reviews link explicit companies without turning global or excluded cases into companies", () => {
const snapshot = structuredClone(seed) as ResearchSnapshot;
assert.equal(snapshot.reviews.filter((r) => r.scope === "companies").length, 214);
assert.equal(snapshot.reviews.filter((r) => r.scope === "dataset").length, 143);
assert.equal(snapshot.reviews.filter((r) => r.scope === "companies").length, 216);
assert.equal(snapshot.reviews.filter((r) => r.scope === "dataset").length, 144);
assert.equal(snapshot.reviews.filter((r) => r.scope === "excluded-candidate").length, 46);
const review = snapshot.reviews.find((r) => r.id === "R4")!;
assert.deepEqual(reviewCompanyIds(snapshot, review), ["AI007", "AI013", "AI021", "AI034"]);
@@ -712,7 +712,8 @@ test("the fifth uncertain cohort separates dated ARR, service run rates, booking
assert.equal(figures.length, 18);
const dated = figures.find((o) => o.id.endsWith("TRELLIS-ARR-AUG"))!;
assert.equal(dated.metric, "arr");
assert.equal(dated.observedAt, "2026-08-24");
assert.equal(dated.observedAt, undefined, "a page maintenance date is not a financial cutoff");
assert.ok(arrFieldGaps(dated, snapshot.asOf).includes("date"));
assert.equal(dated.bound, "≥");
assert.equal(figures.find((o) => o.id.endsWith("INSTA-RUNRATE"))!.metric, "annualized-revenue");
assert.equal(figures.find((o) => o.id.endsWith("INSTA-LAUNCH-ARR"))!.metric, "arr");