chore(monorepo/client): integrate test support

This commit is contained in:
Elian Doran 2025-04-18 11:19:43 +03:00
parent e327c918e1
commit 470e443841
No known key found for this signature in database
8 changed files with 1352 additions and 580 deletions

View File

@ -1,5 +1,5 @@
import { lint } from "./eslint.js";
import { trimIndentation } from "../../../../spec/support/utils.js";
import { trimIndentation } from "@triliumnext/commons";
import { describe, expect, it } from "vitest";
describe("Linter", () => {

View File

@ -1,6 +1,6 @@
import { describe, expect, it } from "vitest";
import { postprocessMermaidSvg } from "./mermaid.js";
import { trimIndentation } from "../../../../spec/support/utils.js";
import { trimIndentation } from "@triliumnext/commons";
describe("Mermaid", () => {
it("converts <br> properly", () => {

View File

@ -1,5 +1,5 @@
import { describe, expect, it, vi } from "vitest";
import { trimIndentation } from "../../../../../../spec/support/utils.js";
import { describe, expect, it } from "vitest";
import { trimIndentation } from "@triliumnext/commons";
import { validateMermaid } from "./mermaid.js";
describe("Mermaid linter", () => {

1916
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -24,6 +24,7 @@
},
"devDependencies": {
"@types/node": "^22.14.1",
"typescript": "5.8.3"
"typescript": "5.8.3",
"vitest": "^3.1.1"
}
}

View File

@ -2,4 +2,5 @@ export * from "./i18n.js";
export * from "./options_interface.js";
export * from "./keyboard_actions_interface.js";
export * from "./hidden_subtree.js";
export * from "./rows.js";
export * from "./rows.js";
export * from "./test-utils.js"

View File

@ -1,5 +1,5 @@
import { describe, it, expect } from "vitest";
import { trimIndentation } from "./utils.js";
import { trimIndentation } from "./test-utils.js";
describe("Utils", () => {
it("trims indentation", () => {