1
0
mirror of https://git.sr.ht/~cadence/bibliogram synced 2025-12-14 10:35:07 +00:00

Start test suite

This commit is contained in:
Cadence Fish
2020-02-05 05:16:27 +13:00
parent 5024dc92af
commit 70348e1934
6 changed files with 2705 additions and 2 deletions

View File

@@ -1,5 +1,4 @@
const constants = require("../constants")
const {Parser} = require("./parser/parser")
function tryMatch(text, against, callback) {
let matched = text.match(against)
@@ -28,6 +27,7 @@ function partsUsername(parts) {
})
}
}
return parts
}
function partsHashtag(parts) {
@@ -41,6 +41,7 @@ function partsHashtag(parts) {
})
}
}
return parts
}
function structure(text) {
@@ -51,3 +52,5 @@ function structure(text) {
}
module.exports.structure = structure
module.exports.partsUsername = partsUsername
module.exports.partsHashtag = partsHashtag