Skip to content

Commit 8c3730e

Browse files
authored
test(unit): check YAML extras presence (#880)
1 parent 92aede5 commit 8c3730e

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

test/vendor.test.js

+29
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,33 @@ describe('YAML', () => {
2424
test('YAML.stringify', () => {
2525
assert.equal(YAML.stringify({ a: 'b' }), 'a: b\n')
2626
})
27+
28+
test('exposes YAML extras', () => {
29+
;[
30+
'parseAllDocuments',
31+
'parseDocument',
32+
'isAlias',
33+
'isCollection',
34+
'isDocument',
35+
'isMap',
36+
'isNode',
37+
'isPair',
38+
'isScalar',
39+
'isSeq',
40+
'Alias',
41+
'Composer',
42+
'Document',
43+
'Schema',
44+
'YAMLSeq',
45+
'YAMLMap',
46+
'YAMLError',
47+
'YAMLParseError',
48+
'YAMLWarning',
49+
'Pair',
50+
'Scalar',
51+
'Lexer',
52+
'LineCounter',
53+
'Parser',
54+
].forEach((k) => assert.ok(k in YAML))
55+
})
2756
})

0 commit comments

Comments
 (0)