File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -8,19 +8,22 @@ import test from 'node:test'
8
8
import { fromMarkdown } from 'mdast-util-from-markdown'
9
9
import { removePosition } from 'unist-util-remove-position'
10
10
import { normalizeHeadings } from '../index.js'
11
+ import * as mod from '../index.js'
12
+
13
+ test ( 'normalizeHeadings' , async ( ) => {
14
+ assert . deepEqual (
15
+ Object . keys ( mod ) . sort ( ) ,
16
+ [ 'normalizeHeadings' ] ,
17
+ 'should expose the public api'
18
+ )
11
19
12
- test ( 'Multiple top-level headings' , async ( ) => {
13
20
await check ( 'no-headings' , 'No-op if there is no headings' )
14
21
await check ( 'no-titles' , 'No-op if there is no top-level headings' )
15
22
await check ( 'one-title' , 'No-op if there is a single top-level heading' )
16
23
await check ( 'two-titles' , 'Makes the second header one level deeper' )
17
24
await check ( 'more-titles' , 'Shifts all other headings one level deeper' )
18
- } )
19
-
20
- test ( 'Level 7' , async ( ) => {
21
25
await check ( 'hierarchy' , 'There is no depth level 7' )
22
26
} )
23
-
24
27
/**
25
28
* @param {string } test
26
29
* @param {string } message
You can’t perform that action at this time.
0 commit comments