Skip to content

Commit 4b7bff0

Browse files
alan-agius4alexeagle
authored andcommitted
test: add skipLibCheck to type-warning test
Declarations in `3.1` are not valid with TypeScript `2.8` which will cause an error and the process will exit with a non zero code.
1 parent b040a3c commit 4b7bff0

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

tests/legacy-cli/e2e/tests/misc/typescript-warning.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,16 @@ import { updateJsonFile } from '../../utils/project';
33

44
export default async function () {
55
// [email protected] is not part of the officially supported range in latest stable.
6-
let unsupportedTsVersion = '2.8.0-dev.20180320';
6+
const unsupportedTsVersion = '2.8.0-dev.20180320';
77

88
await updateJsonFile('src/tsconfig.app.json', configJson => {
9+
// skipLibCheck is required because declerations
10+
// emitted in TS 3.1 are not compatable with TS 2.8
11+
// Thus it will exit with a non zero error code.
12+
configJson.compilerOptions = {
13+
...configJson.compilerOptions,
14+
skipLibCheck: true,
15+
};
916
configJson.angularCompilerOptions = {
1017
...configJson.angularCompilerOptions,
1118
disableTypeScriptVersionCheck: true,

0 commit comments

Comments
 (0)