Skip to content

Commit 94af4d6

Browse files
committed
fix: test
1 parent 0284081 commit 94af4d6

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

packages/comark/test/misc.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ describe('misc', () => {
99

1010
describe('boolean attribute coercion', () => {
1111
it('promotes bare, explicit-true, and explicit-false attrs to :bindings', async () => {
12-
const tree = await parse('::x{flag other="true" off="false" count="5"}\n::')
12+
const tree = await parseMarkdown('::x{flag other="true" off="false" count="5"}\n::')
1313
expect((tree.nodes[0] as any)[1]).toEqual({
1414
':flag': 'true',
1515
other: 'true',
@@ -19,15 +19,15 @@ describe('misc', () => {
1919
})
2020

2121
it('promotes unquoted true/false the same way', async () => {
22-
const tree = await parse('::x{on=true off=false}\n::')
22+
const tree = await parseMarkdown('::x{on=true off=false}\n::')
2323
expect((tree.nodes[0] as any)[1]).toEqual({
2424
on: 'true',
2525
off: 'false',
2626
})
2727
})
2828

2929
it('leaves explicit :bindings and non-boolean strings alone', async () => {
30-
const tree = await parse('::x{:flag="false" label="falsey" zero="0"}\n::')
30+
const tree = await parseMarkdown('::x{:flag="false" label="falsey" zero="0"}\n::')
3131
expect((tree.nodes[0] as any)[1]).toEqual({
3232
':flag': 'false',
3333
label: 'falsey',
@@ -36,7 +36,7 @@ describe('misc', () => {
3636
})
3737

3838
it('applies the same rules to inline components', async () => {
39-
const tree = await parse(':badge{disabled="false" active}')
39+
const tree = await parseMarkdown(':badge{disabled="false" active}')
4040
expect((tree.nodes[0] as any)[1]).toEqual({
4141
disabled: 'false',
4242
':active': 'true',

0 commit comments

Comments
 (0)