Skip to content

Commit 016db0c

Browse files
committed
chore: changed the outDir to entry test
1 parent 6eca706 commit 016db0c

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

test/entry/entry-single-arg.test.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,12 @@ describe('single entry flag', () => {
1010
const { stdout, stderr } = run(__dirname);
1111
const summary = extractSummary(stdout);
1212
const outputDir = 'entry/bin';
13-
expect(summary['Output Directory']).toContain(outputDir);
13+
const outDirectoryFromCompiler = summary['Output Directory'];
14+
const outDirToMatch = outDirectoryFromCompiler
15+
.split('\\')
16+
.slice(outDirectoryFromCompiler.split('\\').length - 2, outDirectoryFromCompiler.split('\\').length)
17+
.join('/');
18+
expect(outDirToMatch).toContain(outputDir);
1419
expect(stderr).toContain('Entry module not found');
1520
stat(resolve(__dirname, './bin'), (err, stats) => {
1621
expect(err).toBe(null);

test/utils/test-utils.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/* eslint-disable @typescript-eslint/explicit-function-return-type */
12
'use strict';
23

34
const path = require('path');

0 commit comments

Comments
 (0)