Revision e4839939b09f717a2b572362e08cdd3ed668445c authored by JoostK on 11 December 2021, 22:55:48 UTC, committed by Alex Rickabaugh on 14 December 2021, 21:08:28 UTC
Now that ViewEngine libraries can no longer be created, the latest TypeScript version that ngcc should be able to process is TypeScript 4.3, i.e. the version of TypeScript that was supported in Angular 12. However, ngcc's integration tests used the TypeScript version of the workspace to create the JavaScript files from TypeScript sources on demand. This introduces friction when upgrading the TypeScript version within the workspace, as changes to TypeScript's emit format may affect ngcc's ability to process it correctly. The on demand creation of JavaScript files was convenient for authoring tests, but it also helped to detect incompatibilities with newer versions of TypeScript. Now that ngcc no longer has to process newer versions of TypeScript, we want to pin the integration suite to use JavaScript code as if it were compiled using TypeScript 4.3, i.e. a version of TypeScript that is actually supported by ngcc. This commit updates the integration test to inline all the generated files directly in the tests, instead of compiling them on demand. This was done by temporarily installing TypeScript 4.3 and using it to create the `loadTestFiles` statement from the original TypeScript inputs. An alternative could have been to install TypeScript 4.3 as an actual dependency in the workspace and using that to continue compiling the integration suite on demand, but this brings some overhead in package installations (TypeScript is ~60MB) and the authoring aspect of ngcc integration test is expected to diminish, now that ngcc's support is no longer a moving target. PR Close #44448
1 parent ab2248e
File | Mode | Size |
---|---|---|
.circleci | ||
.devcontainer | ||
.github | ||
.husky | ||
.ng-dev | ||
.vscode | ||
.yarn | ||
aio | ||
docs | ||
goldens | ||
integration | ||
modules | ||
packages | ||
scripts | ||
third_party | ||
tools | ||
.bazelignore | -rw-r--r-- | 2.8 KB |
.bazelrc | -rw-r--r-- | 6.7 KB |
.bazelversion | -rw-r--r-- | 6 bytes |
.clang-format | -rw-r--r-- | 73 bytes |
.editorconfig | -rw-r--r-- | 245 bytes |
.gitattributes | -rw-r--r-- | 240 bytes |
.gitignore | -rw-r--r-- | 797 bytes |
.gitmessage | -rw-r--r-- | 7.2 KB |
.mailmap | -rw-r--r-- | 51 bytes |
.npmrc | -rw-r--r-- | 21 bytes |
.nvmrc | -rw-r--r-- | 8 bytes |
.prettierrc | -rw-r--r-- | 157 bytes |
.pullapprove.yml | -rw-r--r-- | 47.7 KB |
.yarnrc | -rw-r--r-- | 130 bytes |
BUILD.bazel | -rw-r--r-- | 2.0 KB |
CHANGELOG.md | -rw-r--r-- | 946.6 KB |
CODE_OF_CONDUCT.md | -rw-r--r-- | 1.1 KB |
CONTRIBUTING.md | -rw-r--r-- | 15.8 KB |
LICENSE | -rw-r--r-- | 1.1 KB |
README.md | -rw-r--r-- | 4.7 KB |
WORKSPACE | -rw-r--r-- | 2.6 KB |
browser-providers.conf.js | -rw-r--r-- | 1.8 KB |
gulpfile.js | -rw-r--r-- | 631 bytes |
karma-js.conf.js | -rw-r--r-- | 6.0 KB |
package.json | -rw-r--r-- | 8.4 KB |
renovate.json | -rw-r--r-- | 2.5 KB |
test-events.js | -rw-r--r-- | 259 bytes |
tsconfig-tslint.json | -rw-r--r-- | 149 bytes |
tslint.json | -rw-r--r-- | 4.9 KB |
yarn.lock | -rw-r--r-- | 646.6 KB |
yarn.lock.readme.md | -rw-r--r-- | 1.3 KB |
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...