Refactor tests to split large repo tests into separate files so ava will run them in parallel (reduces test time by ~50%).

This commit is contained in:
David Anson 2023-12-30 19:14:31 -08:00
parent 7d2248d211
commit d0a491d74b
12 changed files with 597 additions and 623 deletions

View file

@ -0,0 +1,14 @@
// @ts-check
"use strict";
const { join } = require("node:path").posix;
const test = require("ava").default;
const { lintTestRepo } = require("./markdownlint-test-repos");
test("https://github.com/mdn/content", (t) => {
const rootDir = "./test-repos/mdn-content";
const globPatterns = [ join(rootDir, "**/*.md") ];
const configPath = join(rootDir, ".markdownlint-cli2.jsonc");
return lintTestRepo(t, globPatterns, configPath);
});