web-app
web-app copied to clipboard
Unit-Testing needs to be set up.
Currently, there are following problems with effective unit testing of components and the entire app.
-
fix: edit sms component spec.ts, incorrect component name 'EditSms' instead of 'EditSMS' leads to error upon running
ng test
- build: add karma jasmine HTML reporter to get detailed error analysis.
- build: (optional) add istanbul-instrument-loader which is a dependency of karma-coverage-istanbul-reporter which offers detailed code coverage.
-
chore: set up
karma.conf.js
to utlizekjhtml
reporter, leaving options to add other reporters if necessary. -
feat: set up
app-testing.module.ts
for exporting all testing modules tospec.ts
files - test: set up all spec.ts files to utilize app.testing.module exports and other corrections necessary for clean test cases.
- refactor: some changes in component.ts files may also be required to pass tests.(eg.)
This is based on #684