Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
test(server/utils): add tests for escapeHtml & unescapeHtml
Panagiotis Papadopoulosf0ba056bb755
diff --git a/src/services/utils.spec.ts b/src/services/utils.spec.tsindex 9669acfd0e..ad5c0841c1 100644--- a/src/services/utils.spec.ts+++ b/src/services/utils.spec.ts@@ -108,11 +108,17 @@ describe("#sanitizeSqlIdentifier", () => {});-// TriliumNextTODO: should use mocks and assert that functions get called-describe.todo("#escapeHtml", () => {});+describe("#escapeHtml", () => {+ it("should re-export 'escape-html' npm module as escapeHtml", () => {+ expect(utils.escapeHtml).toBeTypeOf("function");+ });+});-// TriliumNextTODO: should use mocks and assert that functions get called-describe.todo("#unescapeHtml", () => {});+describe("#unescapeHtml", () => {+ it("should re-export 'unescape' npm module as unescapeHtml", () => {+ expect(utils.unescapeHtml).toBeTypeOf("function");+ });+});describe.todo("#toObject", () => {});