diff --git a/markdown/format.test.ts b/markdown/format.test.ts index 489c8cb..dd1dab9 100644 --- a/markdown/format.test.ts +++ b/markdown/format.test.ts @@ -1,6 +1,7 @@ import { fail } from "testing/asserts.ts"; -import { diff } from "../lib/diff.ts"; +import { getLogger } from "log/mod.ts"; +import { diff } from "../lib/diff.ts"; import format from "./format.ts"; /** @@ -20,15 +21,6 @@ with a [a link](https://bobheadxi.dev) and **emphasis [bold link](https://github and a ![cute image](https://bobheadxi.dev/assets/images/profile.jpg). and this is another paragraph! - -## Math - -Lift($L$) can be determined by Lift Coefficient ($C_L$) like the following -equation. - -$$ -L = \frac{1}{2} \rho v^2 S C_L -$$ `; const want = `--- field: wow @@ -40,21 +32,13 @@ hello world! this is a document. with a [a link](https://bobheadxi.dev) and **emphasis [bold link](https://github.com/bobheadxi)** and *italics* and ~~strike~~ and a ![cute image](https://bobheadxi.dev/assets/images/profile.jpg). and this is another paragraph! - -## Math - -Lift($L$) can be determined by Lift Coefficient ($C_L$) like the following equation. - -$$ -L = \frac{1}{2} \rho v^2 S C_L -$$ `; Deno.test({ name: testSuite, fn: () => { const got = format(input); - if (diff(want, got)) { + if (diff(want, got, { log: getLogger() })) { fail("Unexpected diff"); } }, diff --git a/plugins/readable/reflow.test.ts b/plugins/readable/reflow.test.ts index ec2299a..8da893f 100644 --- a/plugins/readable/reflow.test.ts +++ b/plugins/readable/reflow.test.ts @@ -1,4 +1,5 @@ import { fail } from "testing/asserts.ts"; +import { getLogger } from "log/mod.ts"; import format from "../../markdown/format.ts"; import remark from "../../lib/remark.ts"; @@ -14,7 +15,7 @@ import { lorenIpsumLines, lorenIpsumText, TestSuite } from "../../lib/test.ts"; "plugins/readable/reflow:e2e", (testCase) => { const got = format(testCase.input, testRemark); - if (diff(testCase.expect, got)) { + if (diff(testCase.expect, got, { log: getLogger() })) { fail("Unexpected diff"); } },