Open angulito opened 6 years ago
An update to make this plugin work with 6.4 is sorely needed. Is this repo still being maintained?
@AnguloHerrera The PR works fine for a single test suite file.
But when you have something like that -> https://github.com/PolymerElements/iron-selector/blob/master/test/index.html and the same file is loaded again code coverage for it isn't updated. The problem is caching. When the same file is loaded again instrumentAsset
and/or instrumentHtml
no longer calls instrumentSync
.
@megheaiulian, is it fixed with those changes? https://github.com/AnguloHerrera/web-component-tester-istanbul/tree/develop
I have updated to set into cache the url plus query params.
I don't remove the cache because if I do it, then it can have problems with the rest petitions and the middleware, because they are intercepted, so the petition must be set into cache if it is the first time that the file is called.
Feel free to do a PR to my repository to fix it.
Thanks.
@AnguloHerrera Fixed it with this commit https://github.com/plumelo/web-component-tester-istanbul/commit/52093bde2ae673a16f606e2c36cd16f253e516fc. When instrumented content is already in cache it should be returned ? The else case of if(!cache[asset])
?
Ok, thanks @megheaiulian, now it should be fixed 👍
I have uploaded a new npm package with those changes. I hope this PR is merged and that provisional npm package is not needed anymore. https://www.npmjs.com/package/web-component-tester-istanbulcoverage
@AnguloHerrera Thank you. I too hope it gets merged.
Awesome job !!! Bring me out of confusions after trying almost every method. Thanks too much !