mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-17 22:40:13 +01:00
Reimplement MD013/line-length using micromark tokens.
This commit is contained in:
parent
4072cf7417
commit
3b581a7f6d
10 changed files with 173 additions and 185 deletions
|
|
@ -214,24 +214,6 @@ test("isBlankLine", (t) => {
|
|||
}
|
||||
});
|
||||
|
||||
test("includesSorted", (t) => {
|
||||
t.plan(154);
|
||||
const inputs = [
|
||||
[ ],
|
||||
[ 8 ],
|
||||
[ 7, 11 ],
|
||||
[ 0, 1, 2, 3, 5, 8, 13 ],
|
||||
[ 2, 3, 5, 7, 11, 13, 17, 19 ],
|
||||
[ 1, 3, 5, 7, 9, 11, 13, 15, 17, 19 ],
|
||||
[ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20 ]
|
||||
];
|
||||
for (const input of inputs) {
|
||||
for (let i = 0; i <= 21; i++) {
|
||||
t.is(helpers.includesSorted(input, i), input.includes(i));
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
test("forEachInlineCodeSpan", (t) => {
|
||||
t.plan(99);
|
||||
const testCases =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue