mirror of
https://github.com/Termix-SSH/Termix.git
synced 2026-10-29 14:45:24 +00:00
feat: move snippets backend and tables into a plugin (B2)
This commit is contained in:
1 parent
fdedca39fd
commit
e07221eaf3
51 files changed
+28426
-3553
No files matched your search
@@ -60,6 +60,8 @@ vi.mock("../../utils/database-save-trigger.js", () => ({
|
||||
vi.mock("../../database/db/schema.js", () => ({
|
||||
users: { marker: "users" },
|
||||
hosts: { marker: "hosts" },
|
||||
roles: { marker: "roles" },
|
||||
userRoles: { marker: "userRoles" },
|
||||
}));
|
||||
|
||||
import { createPluginContext, createPluginHandle } from "../../plugins/ctx.js";
|
||||
@@ -195,7 +197,12 @@ describe("ctx.db capability", () => {
|
||||
|
||||
const refs = (await ctx.db.refs()) as Record<string, unknown>;
|
||||
|
||||
expect(Object.keys(refs).sort()).toEqual(["hosts", "users"]);
|
||||
expect(Object.keys(refs).sort()).toEqual([
|
||||
"hosts",
|
||||
"roles",
|
||||
"userRoles",
|
||||
"users",
|
||||
]);
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in new issue
Block a user