mirror of
https://github.com/versia-pub/server.git
synced 2026-03-13 05:49:16 +01:00
refactor(api): ♻️ Move all SSO account linking endpoint logic to OpenID plugin
This commit is contained in:
parent
6d4b4eb13b
commit
74ec563ba5
9 changed files with 267 additions and 286 deletions
|
|
@ -8,7 +8,7 @@ import {
|
|||
test,
|
||||
} from "bun:test";
|
||||
import { ZodError, type ZodTypeAny, z } from "zod";
|
||||
import { Plugin, PluginConfigManager } from "~/packages/plugin-kit";
|
||||
import { Plugin } from "~/packages/plugin-kit";
|
||||
import { type Manifest, manifestSchema } from "~/packages/plugin-kit/schema";
|
||||
import { PluginLoader } from "./loader";
|
||||
|
||||
|
|
@ -154,7 +154,7 @@ describe("PluginLoader", () => {
|
|||
});
|
||||
|
||||
test("loadPlugin should load and return a Plugin instance", async () => {
|
||||
const mockPlugin = new Plugin(new PluginConfigManager(z.object({})));
|
||||
const mockPlugin = new Plugin(z.object({}));
|
||||
mock.module("/some/path/index.ts", () => ({
|
||||
default: mockPlugin,
|
||||
}));
|
||||
|
|
@ -179,7 +179,7 @@ describe("PluginLoader", () => {
|
|||
version: "1.1.0",
|
||||
description: "Doobaee",
|
||||
};
|
||||
const mockPlugin = new Plugin(new PluginConfigManager(z.object({})));
|
||||
const mockPlugin = new Plugin(z.object({}));
|
||||
|
||||
mockReaddir
|
||||
.mockResolvedValueOnce([
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue