mirror of
https://github.com/zadam/trilium.git
synced 2025-11-01 10:55:55 +01:00
refactoring for testing parser
This commit is contained in:
10
spec/parser.spec.js
Normal file
10
spec/parser.spec.js
Normal file
@@ -0,0 +1,10 @@
|
||||
const parser = require('../src/services/search/parser');
|
||||
|
||||
describe("Parser", () => {
|
||||
it("fulltext parser without content", () => {
|
||||
const exps = parser(["hello", "hi"], [], false);
|
||||
|
||||
expect(exps.constructor.name).toEqual("NoteCacheFulltextExp");
|
||||
expect(exps.tokens).toEqual(["hello", "hi"]);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user