Hey!
I'm using web-component-tester just with a JS file. When testing I always get errors during test initialization.

Seems like something wrong with transpilation / index.js selection? Funnily enough, my actual tests still run. Its just that the end result never terminates with OK because that one thing fails.
I've taken a deeper dive on this as I'm running into this with modulizer.
It seems as if this fails for anything relying on a newer version of lodash (above version 3) e.g. polymer-analyzer via @polymer/gen-typescript-declarations.
In WCT we seem to load simply lodash/index.js and the relative path is determined by the relative path of browser.js. If there are multiple versions of lodash the dir structure may end up as
my-element
├ test/
| â”” index.js (points to browser js via ../../)
â”” node_modules/
├ lodash(v4)/
â”” web-component-tester/
├ browser.js
â”” node_modules/
â”” lodash(v3)/
This will make the browser load lodash v4 at the same directory level as wct.
pinging @usergenic for WCT
pinging @aomarks for gen TS
i terminated the error by changing the lodash/index.js into lodash/lodash.js in file node_modules/wct-browser-legacy/browser.js around line 217
Hi @aomarks,
This issue is still happening for me using:
"wct-browser-legacy": "^1.0.2"
whenever another package depends on lodash >= 4. Should it not be "Closed" or is there another branch I should be using instead?
Thanks!
Most helpful comment
i terminated the error by changing the
lodash/index.jsintolodash/lodash.jsin file node_modules/wct-browser-legacy/browser.js around line 217