Tests: cover Matrix runtime wrapper and idHint compatibility

This commit is contained in:
Gustavo Madeira Santana
2026-03-29 12:37:24 -04:00
parent ba9810e60e
commit 6f5813ffff
2 changed files with 23 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
import path from "node:path";
import { pathToFileURL } from "node:url";
import { expect, it } from "vitest";
it("loads the plugin-entry runtime wrapper through native ESM import", async () => {
const wrapperPath = path.join(
process.cwd(),
"extensions",
"matrix",
"src",
"plugin-entry.runtime.js",
);
const wrapperUrl = pathToFileURL(wrapperPath);
const mod = await import(wrapperUrl.href);
expect(mod).toMatchObject({
ensureMatrixCryptoRuntime: expect.any(Function),
handleVerifyRecoveryKey: expect.any(Function),
handleVerificationBootstrap: expect.any(Function),
handleVerificationStatus: expect.any(Function),
});
}, 240_000);

View File

@@ -638,6 +638,7 @@ describe("loadPluginManifestRegistry", () => {
{ name: "provider-style", manifestId: "openai", idHint: "openai-provider" },
{ name: "plugin-style", manifestId: "brave", idHint: "brave-plugin" },
{ name: "sandbox-style", manifestId: "openshell", idHint: "openshell-sandbox" },
{ name: "multi-entry-style", manifestId: "matrix", idHint: "matrix/index" },
{
name: "media-understanding-style",
manifestId: "groq",