The default set of metadata fields provided to all builders executed via the BuilderHarness is controlled programmatically. The BuilderHarness is eventually intended to operate in-memory and without file system access unlike the legacy unit tests. The `cli.cache.enabled` option must therefore be set within the BuilderHarness initialization code. `cli.cache.enabled` set to false provides improved test isolation guarantees by disabling Webpack’s caching.
All TypeScript files have been updated to pass the new eslint-based linting checks. eslint compatible disabling comments have also been added in place of the previous tslint comments.
With this change, the architect can be configured to use a default configuration when it's not provided as part of the target.
Consider the below, where `defaultConfiguration` is configured to `production`. Running `ng build` will be invoked with "production" configuration.
```js
"build": {
"builder": "@angular-devkit/build-angular:browser",
"defaultConfiguration": "production",
"options": {
...
},
"configurations": {
"production": {
...
}
}
}
```
This change integrates the recently introduced internal custom file watching support into the builder test harness. This allows the test harness to directly trigger file changes and allows more comprehensive test isolation for builder watch scenarios.
This change adds an `expectFile` jasmine helper function that reduces the amount of code necessary to check a file's existence, size, or content. Additional contextual information is also displayed when an expectation fails.