mardi 3 mai 2016

Angular 2 Unit testing with 3rd party components

I'm trying to write a unit test for my component which has a primeng piechart directive in it. Primeng uses Chart.js which is included in my index.html and I've added it to my files list in the test config. When I execute my test it says Can't find variable: Chart. If I remove the 3rd party component from my template the test passes. What is the proper way to create a unit test with a 3rd party component?

Aucun commentaire:

Enregistrer un commentaire