Skip to content

Commit b1bca7a

Browse files
test(cli): put two off-grid test-budget headers on the 10 s grid (#34835)
Fixes #34711 Clause-②: no Metadata-protocol: none ## 维护者速读 - 改了什么:两个 CLI 集成测试头部的耗时预算改到 10 秒刻度上(58→60、65→70),另三个头部补上或换成规定类别。 - 为什么改:预算不在刻度上,耗时刷新工具读到就拒绝,回归读数整份「没量」。 - 风险与回滚:只改注释行,不影响运行;回滚即还原这两行。 - 先看:`dev-host-config-artifact-source.integration.test.ts` 第 2 行(除数值外还补了缺失的类别)。 - 两分钟验证:对两个文件调用 `readTestBudget`(`scripts/measure-test-shard-timings.mjs` 导出),预期返回 60 与 70 而不是抛拒绝。 - 需要你做的:无,席位落地。 ## What changes - `serve-multi-node-gate-declaration.integration.test.ts:2`: `58` to `60` (local reading 45.86 s x 1.25 = 57.3, rounded up to the grid). - `dev-host-config-artifact-source.integration.test.ts:2`: `65` to `70` (local reading 50.80 s x 1.25 = 63.5, rounded up). This header also had no `CLASS:` (the grammar refused it independently), so it now names `spawns the real producer once per single-cause fixture`. - Only these two were off-grid. - Three more headers now name a ruled class, SECONDS and REASON untouched: `serve-crypto-provider-plugin-load-failure` and `serve-set-aside-crypto-provider-plugin` (class text replaced), `start-deployment-durability` (CLASS segment was missing). All use `spawns the real producer once per single-cause fixture`. - Left unchanged on purpose: dogfood `service-account-lifecycle` and `service-account-register-key` (20 s, no CLASS). Each is one showcase boot for the whole file, which fits none of the three ruled classes; the class set is not ours to widen. They still refuse `readTestBudget` if the window reads them above 10 s. ## Tests Header comment only; the two files are `integration` tier CLI tests, declared to CI, not run locally. ## Acceptance notes - Declared deviation: no CI reading exists for either file; both values derive from the local readings already in the headers (header rule: reading x 1.25, rounded up). Rounding is up, never down. - Declared deviation: the second file's class was chosen by this PR (five real boots, three of them single-cause controls); say if a different class is wanted. - `readTestBudget` over every header-bearing file on this head: 2 refused (the dogfood pair above; main refused 7). A looser grep also hits a prose line in `ui/packages/plugin-map/src/index.registration.test.tsx:29` (`// test budget: this file timed out...`), a pre-existing false positive of the reader, not a header. - Changeset: none; `packages/cli` ships `dist`, `README.md`, `CHANGELOG.md` only, test files are not published and packages/qa/dogfood is private (`skip-changeset`). ## Verification - `readTestBudget` on both files after the change: `{seconds: 60}` and `{seconds: 70}`, class accepted; before: both refused (58 not on grid; 65 file grammar). - `node scripts/pm/overlap-check.mjs`: VERDICT clean; `check-nul-bytes`: OK. - NOT MEASURED: the full timings diff end to end (needs the CI window captures that PR #34314 consumes). 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_012MmDsS4GoHCgYwA2uv3n3C <!-- signed: repo:objectstack#4 · os-lizheng · session_012MmDsS4GoHCgYwA2uv3n3C --> --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent b633afe commit b1bca7a

5 files changed

Lines changed: 5 additions & 5 deletions

‎packages/cli/test/dev-host-config-artifact-source.integration.test.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// Copyright (c) 2026 ObjectStack. Licensed under the Apache-2.0 license.
2-
// test-budget: 65 — five real boots in one beforeAll (two `os dev` legs on a host config, three CONTROL boots) plus one compile; slowest local reading 50.80 s (shared box, under the verify lock) x 1.25, rounded up
2+
// test-budget: 70 — spawns the real producer once per single-cause fixture: five real boots in one beforeAll (two `os dev` legs on a host config, three CONTROL boots) plus one compile; slowest local reading 50.80 s (shared box, under the verify lock) x 1.25, rounded up
33

44
/**
55
* #31761 — on `os dev` over a HOST config, the boot serves ONE copy of the

‎packages/cli/test/serve-crypto-provider-plugin-load-failure.integration.test.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// Copyright (c) 2026 ObjectStack. Licensed under the Apache-2.0 license.
2-
// test-budget: 40 — spawns `os serve` (src, via runServe) once per single-cause fixture: five boots, three refused and two that reach the ready banner; budget to be re-measured
2+
// test-budget: 40 — spawns the real producer once per single-cause fixture: five boots, three refused and two that reach the ready banner; budget to be re-measured
33

44
/**
55
* `os serve` refuses to boot when a `plugins` entry fails to load and it cannot

‎packages/cli/test/serve-multi-node-gate-declaration.integration.test.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// Copyright (c) 2026 ObjectStack. Licensed under the Apache-2.0 license.
2-
// test-budget: 58 — spawns the real producer once per single-cause fixture: eight `os serve` boots, one per declaration spelling and gate state and one per local-database kind plus its control; local card-container reading 45.86 s of test time (no CI reading yet), x 1.25, rounded up
2+
// test-budget: 60 — spawns the real producer once per single-cause fixture: eight `os serve` boots, one per declaration spelling and gate state and one per local-database kind plus its control; local card-container reading 45.86 s of test time (no CI reading yet), x 1.25, rounded up
33

44
/**
55
* `os serve` asks the multi-node gate about the topology the operator DECLARED,

‎packages/cli/test/serve-set-aside-crypto-provider-plugin.integration.test.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// Copyright (c) 2026 ObjectStack. Licensed under the Apache-2.0 license.
2-
// test-budget: 40 — spawns `os serve` (src, via runServe) once per single-cause fixture: four boots, two refused and two that reach the ready banner; budget to be re-measured
2+
// test-budget: 40 — spawns the real producer once per single-cause fixture: four boots, two refused and two that reach the ready banner; budget to be re-measured
33

44
/**
55
* A stack whose `plugins` lists no plugin instance (no entry with `init`) is

‎packages/cli/test/start-deployment-durability.integration.test.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// Copyright (c) 2026 ObjectStack. Licensed under the Apache-2.0 license.
2-
// test-budget: 40 — six starts that exit before any server answers (three image refusals; the multi-replica refusal, its pass and its memory-driver control), then two real `os start` boots (one on explicit settings; one on the defaults, which also signs up an owner, creates a member and reads the notice as each); the file read 27.6 s on a shared local box (no CI reading yet) x 1.25, rounded up to the next 10 s, and 26.9 s with the three multi-replica starts added
2+
// test-budget: 40 — spawns the real producer once per single-cause fixture: six starts that exit before any server answers (three image refusals; the multi-replica refusal, its pass and its memory-driver control), then two real `os start` boots (one on explicit settings; one on the defaults, which also signs up an owner, creates a member and reads the notice as each); the file read 27.6 s on a shared local box (no CI reading yet) x 1.25, rounded up to the next 10 s, and 26.9 s with the three multi-replica starts added
33

44
/**
55
* #30120, ruling A3 (record 6634240777) — the official image refuses to start

0 commit comments

Comments
 (0)