lathonez / clicker

Ionic 2 + @angular/cli Seed Project : Angular2 + Typescript + Karma + Protractor + Travis
http://lathonez.com/2018/ionic-2-unit-testing/
MIT License
430 stars 137 forks source link

Phantom js #171

Closed muhammedbasilsk closed 7 years ago

muhammedbasilsk commented 7 years ago

Hey @lathonez, I was integrating the phantomJS browser to do unit testing for the project i am currently working on. Thought to share it with you as well.

Please have a look at it.

codecov-io commented 7 years ago

Current coverage is 95.37% (diff: 100%)

No coverage report found for master at 84ed58a.

Powered by Codecov. Last update 84ed58a...41b067f

lathonez commented 7 years ago

Hey,

Thanks a lot for your time on this.

I'm trying to make the testing framework here as close to possible with ng-cli. At the moment the config should be as per ng-cli verbatim.

As soon as I move away from that I have to support it myself, which I'm not interested in at all.

Also I trust the wisdom of the ng-cli community, if they think that we should be running Phantom by default, I'll pull their changes in.

Personally I don't see any benefit whatsover of using Phantom over Chrome. One needs Chrome (or some other real browser) enabled anyway, for debugging purposes. But that's beside the point.

As you have demonstated here, it's a ~2 line change to switch to Phantom if you want to.

Thanks