Fix PR #34942 follow-up CI regressions

This commit is contained in:
Simon Kim 2026-03-21 01:12:13 +09:00
parent 7b12fc6272
commit 7f6d90d2d4
2 changed files with 13 additions and 3 deletions

View File

@ -59,7 +59,7 @@ describe("ensurePluginRegistryLoaded", () => {
expect(mocks.loadOpenClawPlugins).toHaveBeenCalledWith(
expect.objectContaining({
onlyPluginIds: [],
onlyPluginIds: ["telegram"],
throwOnLoadError: true,
}),
);
@ -86,7 +86,7 @@ describe("ensurePluginRegistryLoaded", () => {
expect(mocks.loadOpenClawPlugins).toHaveBeenCalledTimes(2);
expect(mocks.loadOpenClawPlugins).toHaveBeenNthCalledWith(
1,
expect.objectContaining({ onlyPluginIds: [], throwOnLoadError: true }),
expect.objectContaining({ onlyPluginIds: ["telegram"], throwOnLoadError: true }),
);
expect(mocks.loadOpenClawPlugins).toHaveBeenNthCalledWith(
2,

View File

@ -32,6 +32,16 @@ const EXCLUDED_MUTABLE_OR_RUNTIME_MANAGED = [
"whatsapp.creds.json",
];
function compareCredentialMatrixIds(left: string, right: string): number {
if (left < right) {
return -1;
}
if (left > right) {
return 1;
}
return 0;
}
export function buildSecretRefCredentialMatrix(): SecretRefCredentialMatrixDocument {
const entries: CredentialMatrixEntry[] = listSecretTargetRegistryEntries()
.map((entry) => ({
@ -46,7 +56,7 @@ export function buildSecretRefCredentialMatrix(): SecretRefCredentialMatrixDocum
? { notes: "Google Chat compatibility exception: sibling ref field remains canonical." }
: {}),
}))
.toSorted((a, b) => a.id.localeCompare(b.id));
.toSorted((a, b) => compareCredentialMatrixIds(a.id, b.id));
return {
version: 1,