diff --git a/docs/ci.md b/docs/ci.md index f981309aed6..f537a71dbce 100644 --- a/docs/ci.md +++ b/docs/ci.md @@ -51,7 +51,7 @@ Local changed-lane logic lives in `scripts/changed-lanes.mjs` and is executed by On pushes, the `checks` matrix adds the push-only `compat-node22` lane. On pull requests, that lane is skipped and the matrix stays focused on the normal test/channel lanes. -The slowest Node test families are split into include-file shards so each job stays small: channel contracts split registry and core coverage into four balanced shards each, auto-reply reply command tests split into four include-pattern shards, and the other large auto-reply reply prefix groups split into two shards each. `check-additional` also separates package-boundary compile/canary work from runtime topology gateway/architecture work. +The slowest Node test families are split into include-file shards so each job stays small: channel contracts split registry and core coverage into eight balanced shards each, auto-reply reply command tests split into four include-pattern shards, and the other large auto-reply reply prefix groups split into two shards each. `check-additional` also separates package-boundary compile/canary work from runtime topology gateway/architecture work. ## Runners diff --git a/scripts/lib/channel-contract-test-plan.mjs b/scripts/lib/channel-contract-test-plan.mjs index 52c6db8e286..6cb423a58e7 100644 --- a/scripts/lib/channel-contract-test-plan.mjs +++ b/scripts/lib/channel-contract-test-plan.mjs @@ -14,7 +14,7 @@ function listContractTestFiles(rootDir = "src/channels/plugins/contracts") { export function createChannelContractTestShards() { const rootDir = "src/channels/plugins/contracts"; - const suffixes = ["a", "b", "c", "d"]; + const suffixes = ["a", "b", "c", "d", "e", "f", "g", "h"]; const groups = Object.fromEntries( ["registry", "core"].flatMap((family) => suffixes.map((suffix) => [`checks-fast-contracts-channels-${family}-${suffix}`, []]), diff --git a/test/scripts/channel-contract-test-plan.test.ts b/test/scripts/channel-contract-test-plan.test.ts index 7a3a34a9a5a..81b845c2410 100644 --- a/test/scripts/channel-contract-test-plan.test.ts +++ b/test/scripts/channel-contract-test-plan.test.ts @@ -16,54 +16,23 @@ function listContractTests(rootDir = "src/channels/plugins/contracts"): string[] describe("scripts/lib/channel-contract-test-plan.mjs", () => { it("splits channel contracts into focused shards", () => { + const suffixes = ["a", "b", "c", "d", "e", "f", "g", "h"]; + expect( createChannelContractTestShards().map((shard) => ({ checkName: shard.checkName, runtime: shard.runtime, task: shard.task, })), - ).toEqual([ - { - checkName: "checks-fast-contracts-channels-registry-a", - runtime: "node", - task: "contracts-channels", - }, - { - checkName: "checks-fast-contracts-channels-registry-b", - runtime: "node", - task: "contracts-channels", - }, - { - checkName: "checks-fast-contracts-channels-registry-c", - runtime: "node", - task: "contracts-channels", - }, - { - checkName: "checks-fast-contracts-channels-registry-d", - runtime: "node", - task: "contracts-channels", - }, - { - checkName: "checks-fast-contracts-channels-core-a", - runtime: "node", - task: "contracts-channels", - }, - { - checkName: "checks-fast-contracts-channels-core-b", - runtime: "node", - task: "contracts-channels", - }, - { - checkName: "checks-fast-contracts-channels-core-c", - runtime: "node", - task: "contracts-channels", - }, - { - checkName: "checks-fast-contracts-channels-core-d", - runtime: "node", - task: "contracts-channels", - }, - ]); + ).toEqual( + ["registry", "core"].flatMap((family) => + suffixes.map((suffix) => ({ + checkName: `checks-fast-contracts-channels-${family}-${suffix}`, + runtime: "node", + task: "contracts-channels", + })), + ), + ); }); it("covers every channel contract test exactly once", () => {