Skip to content

Commit cffbdb3

Browse files
committed
tests: add test on error code
1 parent 8deec71 commit cffbdb3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/loader/error-test/loader-error.test.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ describe('loader error regression test for #1581', () => {
77
it(`should not ignore loader's error produce a failing build`, () => {
88
// Ignoring assertion on stderr because ts-loader is producing depreciation warnings
99
// with webpack@v5.0.0-beta.24 -> https://github.com/TypeStrong/ts-loader/issues/1169
10-
const { stdout } = run(__dirname, [], false);
11-
10+
const { stdout, exitCode } = run(__dirname, [], false);
11+
expect(exitCode).not.toEqual(0);
1212
expect(stdout).toContain('[1 error]');
1313
expect(stdout).toContain(`Cannot assign to 'foobar' because it is a constant`);
1414
});

0 commit comments

Comments
 (0)