Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nodejs version incompatible #71

Closed
aaronmayo opened this issue Jul 27, 2017 · 4 comments
Closed

Nodejs version incompatible #71

aaronmayo opened this issue Jul 27, 2017 · 4 comments

Comments

@aaronmayo
Copy link

When I use node v4.4.7, it's OK to run example mocha, but will occur error when run example e2e,

C:\Users\MEIAA\Desktop\pact-js-master\examples\e2e\test\consumer.spec.js:23
const { somethingLike: like, term, eachLike } = pact.Matchers
^
SyntaxError: Unexpected token {
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:373:25)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at C:\Users\MEIAA\Desktop\pact-js-master\examples\e2e\node_modules\mocha\lib\mocha.js:230:27
at Array.forEach (native)
at Mocha.loadFiles (C:\Users\MEIAA\Desktop\pact-js-master\examples\e2e\node_modules\mocha\lib\mocha.js:227:14)
at Mocha.run (C:\Users\MEIAA\Desktop\pact-js-master\examples\e2e\node_modules\mocha\lib\mocha.js:495:10)
at Object. (C:\Users\MEIAA\Desktop\pact-js-master\examples\e2e\node_modules\mocha\bin_mocha:469:18)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Function.Module.runMain (module.js:441:10)
at startup (node.js:139:18)
at node.js:968:3

Then I change to Node v6.11.0, example e2e and mocha both occur this error,

ERROR: The process "10928" not found.
1) "before all" hook
2) "after all" hook

0 passing (3s)
2 failing

  1. Pact "before all" hook:
    Uncaught Error: Command failed: taskkill /f /t /pid 10928
    ERROR: The process "10928" not found.

    at checkExecSyncError (child_process.js:481:13)
    at Object.execSync (child_process.js:521:13)
    at Server.stop (C:\Users\MEIAA\Desktop\pact-js-master\node_modules@pact-foundation\pact-node\src\server.js:138:7)
    at Server. (C:\Users\MEIAA\Desktop\pact-js-master\node_modules@pact-foundation\pact-node\src\server.js:117:8)
    at maybeClose (internal/child_process.js:886:16)
    at Socket. (internal/child_process.js:342:11)
    at Pipe._handle.close [as _onclose] (net.js:497:12)

  2. Pact "after all" hook:
    Error: connect ECONNREFUSED 127.0.0.1:1234
    at Object.exports._errnoException (util.js:1018:11)
    at exports._exceptionWithHostPort (util.js:1041:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1086:14)

So, what's the propper version of Node?

@bethesque
Copy link
Member

Can we have these examples running in travis @mefellows?

@mefellows
Copy link
Member

Yes we can! I'll get it done this weekend.

@bethesque
Copy link
Member

Enjoy those productive weekends while you can... :P

@mefellows
Copy link
Member

👶

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants