fix(ci): repair seam drift and matrix test timing

This commit is contained in:
Peter Steinberger
2026-04-04 04:19:58 +01:00
parent d7ba6d3e68
commit 2416e2d51d
5 changed files with 41 additions and 32 deletions

View File

@@ -2,6 +2,7 @@ import fs from "node:fs/promises";
import os from "node:os";
import path from "node:path";
import { afterAll, beforeAll, describe, expect, it, vi } from "vitest";
import type { PluginManifestRegistry } from "../plugins/manifest-registry.js";
import { createConfigIO } from "./io.js";
import type { OpenClawConfig } from "./types.js";
@@ -10,14 +11,16 @@ import type { OpenClawConfig } from "./types.js";
// test exercise the exact code path that caused the bug: AJV injecting
// defaults during the write-back validation pass.
const mockLoadPluginManifestRegistry = vi.hoisted(() =>
vi.fn(() => ({
diagnostics: [],
plugins: [],
})),
vi.fn(
(): PluginManifestRegistry => ({
diagnostics: [],
plugins: [],
}),
),
);
vi.mock("../plugins/manifest-registry.js", () => ({
loadPluginManifestRegistry: (...args: unknown[]) => mockLoadPluginManifestRegistry(...args),
loadPluginManifestRegistry: mockLoadPluginManifestRegistry,
}));
describe("config io write", () => {
@@ -424,8 +427,17 @@ describe("config io write", () => {
plugins: [
{
id: "bluebubbles",
name: "BlueBubbles",
version: "0.0.0-test",
origin: "bundled",
channels: ["bluebubbles"],
providers: [],
cliBackends: [],
skills: [],
hooks: [],
rootDir: "/mock/bluebubbles",
source: "bundled",
manifestPath: "/mock/bluebubbles/openclaw.plugin.json",
channelCatalogMeta: {
id: "bluebubbles",
label: "BlueBubbles",

View File

@@ -3,6 +3,7 @@ import type { ChannelAccountSnapshot } from "../channels/plugins/types.core.js";
import type { ChannelStatusIssue } from "../channels/plugins/types.js";
import type { OpenClawConfig } from "../config/config.js";
export type { ChannelAccountSnapshot } from "../channels/plugins/types.core.js";
export type { ChannelStatusIssue } from "../channels/plugins/types.js";
export { isRecord } from "../channels/plugins/status-issues/shared.js";
export {
appendMatchMetadata,