theintern / intern-tutorial

Learn how to use Intern by following this tutorial!
http://theintern.io
144 stars 44 forks source link

ECONNREFUSED when running functional tests #10

Closed ilkka closed 9 years ago

ilkka commented 9 years ago

The tutorial worked just fine for me up until the moment when I tried to run my functional tests using Sauce Labs:

$ SAUCE_USERNAME=... SAUCE_ACCESS_KEY=... ./node_modules/.bin/intern-runner config=tests/intern
Listening on 0.0.0.0:9000
Starting tunnel...
Ready
Using no proxy for connecting to Sauce Labs REST API.
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>
Error: [POST http://(redacted)@localhost:4444/wd/hub/session] connect ECONNREFUSED
Error: connect ECONNREFUSED
  at exports._errnoException  <util.js:742:11>
  at Object.afterConnect [as oncomplete]  <net.js:989:19>

TOTAL: tested 0 platforms, 0/0 tests failed; fatal error occurred

I'm confused. 'No proxy' but still it's trying to connect to localhost:4444? Also, on the first run it hung for >10 seconds at 'Starting tunnel...'.

ilkka commented 9 years ago

I was able to do this in the same shell so I think my environment is fine:

intern-tutorial $ cd node_modules/intern
intern-tutorial/node_modules/intern $ node
> var SauceLabsTunnel = require('digdug/SauceLabsTunnel')
undefined
> var t = new SauceLabsTunnel();
undefined
> t.start().then(function () { console.log('YES'); });
{ cancel: [Function], then: [Function] }
> YES
ilkka commented 9 years ago

Aw geez I'm a complete dingus :D I had Node 0.11 from nvm and that's what broke it. So I guess this is a heads up, "Doesn't work on Node 0.11" :)

csnover commented 9 years ago

All odd-numbered versions of Node.js (0.9, 0.11, 0.13, etc.) are unstable development versions that are not supported.