-
Notifications
You must be signed in to change notification settings - Fork 11.9k
Closed
Labels
P1Impacts a large percentage of users; if a workaround exists it is partial or overly painfulImpacts a large percentage of users; if a workaround exists it is partial or overly painfuleffort2: medium (days)severity2: inconvenienttype: bug/fix
Description
Bug Report or Feature Request (mark with an x
)
- [x] bug report
- [ ] feature request
Versions.
@angular/cli: 1.0.0
node: 6.9.1
os: darwin x64 (El Capitan)
@angular/common: 4.0.1
@angular/compiler: 4.0.1
@angular/core: 4.0.1
@angular/forms: 4.0.1
@angular/http: 4.0.1
@angular/platform-browser: 4.0.1
@angular/platform-browser-dynamic: 4.0.1
@angular/router: 4.0.1
@angular/cli: 1.0.0
@angular/compiler-cli: 4.0.1
Repro steps.
- Perform a fresh install with
ng new
- Add the following test to
src/app/app.component.spec.ts
it('should not compile if there are TypeScript errors', () => {
const myFunc = (arg: string) => {};
myFunc(1);
});
- run
ng test --single-run
and see that there are no errors - run
tsc --project src/tsconfig.spec.json
and see a type error
The log given by the failure.
No errors are reported. The code compiles and the tests pass.
Desired functionality.
The following compilation error should be reported and the tests should not be run:
src/app/app.component.spec.ts(39,12): error TS2345: Argument of type '1' is not assignable to parameter of type 'string'.
tonivj5, mmmichl, shanesmith and griswold
Metadata
Metadata
Assignees
Labels
P1Impacts a large percentage of users; if a workaround exists it is partial or overly painfulImpacts a large percentage of users; if a workaround exists it is partial or overly painfuleffort2: medium (days)severity2: inconvenienttype: bug/fix