tomastrajan / angular-ngrx-material-starter

Angular, NgRx, Angular CLI & Angular Material Starter Project
https://tomastrajan.github.io/angular-ngrx-material-starter
MIT License
2.82k stars 919 forks source link

Use styles in Karma unit tests #381

Closed tomastrajan closed 5 years ago

tomastrajan commented 5 years ago

Describe the feature you'd like:

Styles seem to be injected into karma tests but the components are only partially formatted. We want karma unit tests to look similar as they would in real application

Other information:

angular.json test styles vs karma files and processors ?

Or maybe this is not necessary at all, thoughts ?

timdeschryver commented 5 years ago

It doesn't really bother me. I often use the watch command so I'm not really seeing the components anyways.

You can see the components when you run the e2e tests tho, but this is a bit heavier.

tomastrajan commented 5 years ago

@timdeschryver this was actually fixed already by adjusting styles path in angualr.json for correct entrypoint to the styles file. Currently karma tests get proper fonts and material components also look right there are just no themes which is not a big deal ;) I just forgot to reference issue from the commit message.