Skip to content

Commit 37a2c6f

Browse files
authored
test: fix generate coverage report & test failure when not supported language with Prismjs (#271)
* test: fix test failure when not supported language with Prismjs * test: fix lcov.info is empty
1 parent 837008b commit 37a2c6f

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

.nycrc.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# https://github.com/istanbuljs/nyc#common-configuration-options
2+
all: true

test/prism.spec.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,8 @@ describe('prismHighlight', () => {
7777
'}'
7878
].join('\n');
7979

80-
// Use language: 'plain' to simplify the test
81-
const result = prismHighlight(input, { tab: ' ', lang: 'plain' });
80+
// Use language: 'plain-text' for not supported language with Prism
81+
const result = prismHighlight(input, { tab: ' ', lang: 'plain-text' });
8282

8383
result.should.contains(escapeHTML(input.replace(/\t/g, ' ')));
8484

0 commit comments

Comments
 (0)