question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error when running tests with karma and phantomjs

See original GitHub issue

Hello. 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:closed
  • Created 5 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
GerkinDevcommented, Sep 15, 2019

E2E testing was delegated to Cypress, which will soon include adapter for browserstack for IEx testing

1reaction
GerkinDevcommented, Feb 26, 2019

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.

Read more comments on GitHub >

github_iconTop 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 >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found