mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-16 22:10:13 +01:00
Update to use named exports via / /async /promise /sync, simplify references via self-referencing, refine examples.
This commit is contained in:
parent
e41f034bef
commit
8da43dd246
96 changed files with 635 additions and 548 deletions
|
|
@ -1,7 +1,7 @@
|
|||
// @ts-check
|
||||
|
||||
import test from "ava";
|
||||
import markdownlint from "../lib/markdownlint.mjs";
|
||||
import { applyFix, applyFixes } from "markdownlint";
|
||||
|
||||
test("applyFix", (t) => {
|
||||
t.plan(4);
|
||||
|
|
@ -46,7 +46,7 @@ test("applyFix", (t) => {
|
|||
for (const testCase of testCases) {
|
||||
const [ line, fixInfo, lineEnding, expected ] = testCase;
|
||||
// @ts-ignore
|
||||
const actual = markdownlint.applyFix(line, fixInfo, lineEnding);
|
||||
const actual = applyFix(line, fixInfo, lineEnding);
|
||||
t.is(actual, String(expected), "Incorrect fix applied.");
|
||||
}
|
||||
});
|
||||
|
|
@ -524,7 +524,7 @@ test("applyFixes", (t) => {
|
|||
for (const testCase of testCases) {
|
||||
const [ input, errors, expected ] = testCase;
|
||||
// @ts-ignore
|
||||
const actual = markdownlint.applyFixes(input, errors);
|
||||
const actual = applyFixes(input, errors);
|
||||
t.is(actual, String(expected), "Incorrect fix applied.");
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue