Error when running tests with karma and phantomjs
See original GitHub issueHello. I’m tying to write tests on the project I work and I can’t, because I get next error:
PhantomJS 2.1.1 (Linux 0.0.0) ERROR
SyntaxError: Use of reserved word 'class'
at http://localhost:8081webpack:///node_modules/vuejs-datatable/src/classes/settings.js:3:0 <- index.js:15069
Is it possible somehow to fix or to avoid it? Thanks.
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Karma is not able to run test cases on phantomJS #558 - GitHub
I have been trying to get Karma to run tests on PhantomJS for the last couple of hours and seem to be stuck...
Read more >Karma test fails when running on PhantomJS - Stack Overflow
SyntaxError: Unexpected token ')' at karma-test-shim.js:31. Line 31 is the following : .then(() => Promise.all([.
Read more >Error with Karma test runner and PhantomJS
I've included "karma-phantomjs-launcher" and "karma-teamcity-reporter" plugins. I'm using the command line runner in my build step with the ...
Read more >Error while testing with PhantomJs, karma and jasmine.
I'm using highcharts-angular and the map works fine on the browser. However when I try to run tests with ng-test I get errors....
Read more >Karma tests, PhantomJS error: Could not find module 'events'
[Solved]-Karma tests, PhantomJS error: Could not find module 'events'-phantom.js ... Well, according to an answer to a similar question on SO it's not...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
E2E testing was delegated to Cypress, which will soon include adapter for browserstack for IEx testing
Even if I guess you don’t work on the project anymore, and the thread is old, I’d like to let you know that I’m totally rewriting this part of the package.
Anyway, concerning your problem, it seems to be an ES6 problem, and is related to #57 & #60. It actually seems that other people have the same problem using PhantomJS 2.1.1. The build process was totally rewritten with #47, and the next release will include an es5-compatible babel configuration. So the next release will fix the problem.