Skip to content

Commit 8dba4c8

Browse files
clydinangular-robot[bot]
authored andcommitted
test: add a standard decorator support E2E test
The added E2E test checks that it is possible to compile an application with experimental decorators disabled. The test also executes the unit tests inside a CLI generated project.
1 parent f99e106 commit 8dba4c8

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
import { ng } from '../../utils/process';
2+
import { updateTsConfig } from '../../utils/project';
3+
4+
export default async function () {
5+
// Update project to disable experimental decorators
6+
await updateTsConfig((json) => {
7+
json['compilerOptions']['experimentalDecorators'] = false;
8+
});
9+
10+
// Default production build
11+
await ng('build');
12+
13+
// Production build with JIT
14+
await ng('build', '--no-aot', '--no-build-optimizer');
15+
16+
// Default development build
17+
await ng('build', '--configuration=development');
18+
19+
// Development build with JIT
20+
await ng('build', '--configuration=development', '--no-aot');
21+
22+
// Unit tests (JIT only)
23+
await ng('test', '--no-watch');
24+
25+
// E2E tests to ensure application functions in a browser
26+
await ng('e2e');
27+
}

0 commit comments

Comments
 (0)