mirror of
https://github.com/bknd-io/bknd/
synced 2026-08-02 08:06:00 +00:00
move sort plugin to data plugins
This commit is contained in:
@@ -731,7 +731,7 @@ describe("sort plugin", () => {
|
|||||||
.execute();
|
.execute();
|
||||||
|
|
||||||
// create normal task
|
// create normal task
|
||||||
const { data: task2 } = await mutator.insertOne({ title: "Task 2" });
|
await mutator.insertOne({ title: "Task 2" });
|
||||||
|
|
||||||
// update the null task to have a position
|
// update the null task to have a position
|
||||||
const nullTask = await app.connection.kysely
|
const nullTask = await app.connection.kysely
|
||||||
@@ -791,7 +791,6 @@ describe("sort plugin", () => {
|
|||||||
const { data: tasks } = await app.em.repo("tasks").findMany({
|
const { data: tasks } = await app.em.repo("tasks").findMany({
|
||||||
sort: { by: "position", dir: "asc" },
|
sort: { by: "position", dir: "asc" },
|
||||||
});
|
});
|
||||||
console.dir(tasks, { depth: null });
|
|
||||||
|
|
||||||
expect(tasks.length).toBe(2);
|
expect(tasks.length).toBe(2);
|
||||||
expect(tasks[0].id).toBe(task2.id);
|
expect(tasks[0].id).toBe(task2.id);
|
||||||
@@ -9,4 +9,4 @@ export { syncTypes, type SyncTypesOptions } from "./dev/sync-types.plugin";
|
|||||||
export { syncSecrets, type SyncSecretsOptions } from "./dev/sync-secrets.plugin";
|
export { syncSecrets, type SyncSecretsOptions } from "./dev/sync-secrets.plugin";
|
||||||
export { timestamps, type TimestampsPluginOptions } from "./data/timestamps.plugin";
|
export { timestamps, type TimestampsPluginOptions } from "./data/timestamps.plugin";
|
||||||
export { emailOTP, type EmailOTPPluginOptions } from "./auth/email-otp.plugin";
|
export { emailOTP, type EmailOTPPluginOptions } from "./auth/email-otp.plugin";
|
||||||
export { sort, type SortPluginOptions } from "./sort.plugin";
|
export { sort, type SortPluginOptions } from "./data/sort.plugin";
|
||||||
|
|||||||
Reference in New Issue
Block a user