@lowlighter/markdown 1.2.3 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/renderer_test.ts CHANGED
@@ -2,18 +2,18 @@ import { expect, test } from "@libs/testing"
2
2
  import { Renderer } from "./renderer.ts"
3
3
  import pluginGfm from "./plugins/gfm.ts"
4
4
 
5
- test("deno")("Renderer.render() renders markdown", async () => {
5
+ test("deno")("`Renderer.render()` renders markdown", async () => {
6
6
  const markdown = new Renderer()
7
7
  await expect(markdown.render("# foo")).resolves.toBe("<h1>foo</h1>")
8
8
  await expect(Renderer.render("# foo")).resolves.toBe("<h1>foo</h1>")
9
9
  })
10
10
 
11
- test("deno")("Renderer.with() instantiates a new customized renderer", async () => {
11
+ test("deno")("`Renderer.with()` instantiates a new customized renderer", async () => {
12
12
  const markdown = await Renderer.with({ plugins: ["./plugins/gfm.ts", new URL("./plugins/gfm.ts", import.meta.url), pluginGfm] })
13
13
  await expect(markdown.render("# foo")).resolves.toBe("<h1>foo</h1>")
14
14
  })
15
15
 
16
- test("deno")("Renderer.with() honors throw option when creating a new customized renderer", async () => {
16
+ test("deno")("`Renderer.with()` honors throw option when creating a new customized renderer", async () => {
17
17
  await expect(Renderer.with({ plugins: ["unknown"], throw: false })).resolves.toBeInstanceOf(Renderer)
18
18
  await expect(Renderer.with({ plugins: ["unknown"], throw: true })).rejects.toThrow(ReferenceError)
19
19
  })