fix(ci): regenerate Swift protocol model

This commit is contained in:
Vincent Koc
2026-06-21 22:19:10 +08:00
parent 6441e56465
commit b84665222c
3 changed files with 71 additions and 35 deletions

View File

@@ -807,6 +807,21 @@ describe("scripts/changed-lanes", () => {
});
});
it("runs changed-check app tests under the parent heavy-check lock", () => {
const result = detectChangedLanes([
"apps/shared/OpenClawKit/Sources/OpenClawProtocol/GatewayModels.swift",
]);
const plan = createChangedCheckPlan(result, { env: { PATH: "/usr/bin" } });
const testCommand = plan.commands.find((command) => command.args[0] === "test:macos:ci");
expect(testCommand?.env).toEqual({
OPENCLAW_OXLINT_SKIP_LOCK: "1",
OPENCLAW_TEST_HEAVY_CHECK_LOCK_HELD: "1",
OPENCLAW_TSGO_HEAVY_CHECK_LOCK_HELD: "1",
PATH: "/usr/bin",
});
});
it("routes core test-only changes to core test lanes only", () => {
const result = detectChangedLanes([
"packages/normalization-core/src/string-normalization.test.ts",
@@ -1315,10 +1330,12 @@ describe("scripts/changed-lanes", () => {
name: "prompt snapshot drift",
args: ["prompt:snapshots:check"],
});
expect(plan.commands).toContainEqual({
name: "prompt snapshot owner test",
args: ["test:serial", "test/scripts/prompt-snapshots.test.ts"],
});
expect(plan.commands).toContainEqual(
expect.objectContaining({
name: "prompt snapshot owner test",
args: ["test:serial", "test/scripts/prompt-snapshots.test.ts"],
}),
);
});
it("runs the prompt snapshot owner test for model fixture generator surfaces", () => {
@@ -1332,10 +1349,12 @@ describe("scripts/changed-lanes", () => {
const result = detectChangedLanes(["scripts/sync-codex-model-prompt-fixture.ts"]);
const plan = createChangedCheckPlan(result);
expect(plan.commands).toContainEqual({
name: "prompt snapshot owner test",
args: ["test:serial", "test/scripts/prompt-snapshots.test.ts"],
});
expect(plan.commands).toContainEqual(
expect.objectContaining({
name: "prompt snapshot owner test",
args: ["test:serial", "test/scripts/prompt-snapshots.test.ts"],
}),
);
});
it("runs runtime sidecar baseline checks for baseline owner surfaces", () => {
@@ -1355,10 +1374,12 @@ describe("scripts/changed-lanes", () => {
name: "runtime sidecar baseline",
args: ["runtime-sidecars:check"],
});
expect(plan.commands).toContainEqual({
name: "runtime sidecar owner test",
args: ["test:serial", "src/plugins/bundled-plugin-metadata.test.ts"],
});
expect(plan.commands).toContainEqual(
expect.objectContaining({
name: "runtime sidecar owner test",
args: ["test:serial", "src/plugins/bundled-plugin-metadata.test.ts"],
}),
);
});
it("guards release metadata package changes to the top-level version field", () => {
@@ -1472,10 +1493,12 @@ describe("scripts/changed-lanes", () => {
bin: "node",
}),
);
expect(plan.commands).toContainEqual({
name: "macOS app CI tests",
args: ["test:macos:ci"],
});
expect(plan.commands).toContainEqual(
expect.objectContaining({
name: "macOS app CI tests",
args: ["test:macos:ci"],
}),
);
}
});
@@ -1484,10 +1507,12 @@ describe("scripts/changed-lanes", () => {
const plan = createChangedCheckPlan(result);
expect(shouldRunAppcastOwnerTest(result.paths)).toBe(true);
expect(plan.commands).toContainEqual({
name: "appcast owner tests",
args: ["test:serial", "test/appcast.test.ts", "test/scripts/make-appcast.test.ts"],
});
expect(plan.commands).toContainEqual(
expect.objectContaining({
name: "appcast owner tests",
args: ["test:serial", "test/appcast.test.ts", "test/scripts/make-appcast.test.ts"],
}),
);
expect(plan.commands.map((command) => command.name)).not.toContain("macOS app CI tests");
});
@@ -1502,10 +1527,12 @@ describe("scripts/changed-lanes", () => {
});
expect(plan.commands.map((command) => command.args[0])).toContain("lint:apps");
expect(plan.commands).toContainEqual({
name: "macOS app CI tests",
args: ["test:macos:ci"],
});
expect(plan.commands).toContainEqual(
expect.objectContaining({
name: "macOS app CI tests",
args: ["test:macos:ci"],
}),
);
});
it("keeps macOS app CI tests out of Android-only app changes", () => {