Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
quarto-dev
GitHub Repository: quarto-dev/quarto-cli
Path: blob/main/tests/smoke/render/render-commonmark.test.ts
12925 views
1
/*
2
* render.jupyter.test.ts
3
*
4
* Copyright (C) 2020-2022 Posit Software, PBC
5
*
6
*/
7
import { join } from "../../../src/deno_ral/path.ts";
8
import { docs, outputForInput } from "../../utils.ts";
9
import { ensureFileRegexMatches } from "../../verify.ts";
10
import { testRender } from "./render.ts";
11
12
const tests = [
13
{ file: "commonmark-plain.qmd" },
14
{ file: "commonmark-r.qmd" },
15
{ file: "commonmark-python.qmd"},
16
{ file: "commonmark-julia.qmd" },
17
{ file: "commonmark-julianative.qmd" },
18
];
19
tests.forEach((test) => {
20
const input = docs(join("markdown", test.file));
21
const output = outputForInput(input, "commonmark");
22
testRender(
23
input,
24
"commonmark",
25
true,
26
[ensureFileRegexMatches(output.outputPath, [
27
/^# test$/gm,
28
])],
29
);
30
});
31
32