Has anyone successfully used theintern.github.io/intern on CircleCI. If so could you share how?
my circle.yml
machine:
node:
version: 5.6.0
environment:
IN_CI: 1
NODE_ENV: production
SELENIUM_HOST: hub.browserstack.com
SELENIUM_PORT: 80
BS_AUTOMATE_PROJECT: "Run on circleCI"
BS_AUTOMATE_BUILD: "build No. $CIRCLE_BUILD_NUM for circleCI"
SELENIUM_PLATFORM: WINDOWS
SELENIUM_BROWSER: IE
SELENIUM_VERSION: 9
test:
pre:
- npm run build:webpack:dev
- wget http://chromedriver.storage.googleapis.com/2.22/chromedriver_linux32.zip
- unzip chromedriver_linux32.zip
- ./chromedriver --port=4444 --url-base=we/hub &
override:
- npm test
```
my package.json
```
{
"scripts": {
"test": "node ./node_modules/.bin/intern-runner config=tests/intern.js"
}
}
```
my config tests/intern.js
```
define({
capabilities: {
'browserstack.selenium_version': '2.45.0'
},
environments: [
// { browserName: 'internet explorer', version: '11', platform: 'WIN8' },
// { browserName: 'internet explorer', version: '10', platform: 'WIN8' },
// { browserName: 'internet explorer', version: '9', platform: 'WINDOWS' },
// { browserName: 'firefox', version: '37', platform: [ 'WINDOWS', 'MAC' ] },
{ browserName: 'chrome', version: '39', platform: [ 'WINDOWS', 'MAC' ] }
// { browserName: 'safari', version: '8', platform: 'MAC' }
],
maxConcurrency: 2,
tunnel: 'NullTunnel',
loaderOptions: {
packages: [ { name: 'myPackage', location: '.' } ]
},
suites: [ /* 'myPackage/tests/foo', 'myPackage/tests/bar' */ ],
functionalSuites: [ /* 'myPackage/tests/functional' */ ],
excludeInstrumentation: /^(?:tests|node_modules)\//
});
```
note I'm using the `NullTunnel` as I'd like CircleCI to run the tests until I'm ready to pay for browserstack or saucelabs.
I get the following error
```
npm test
> @project
> node ./node_modules/.bin/intern-runner config=tests/intern.js
> @project
> node ./node_modules/.bin/intern-runner config=tests/intern.js
Listening on 0.0.0.0:9000
Listening on 0.0.0.0:9000
Tunnel started
Suite chrome 39 on WINDOWS FAILED
Error: [POST http://localhost:4444/wd/hub/session] connect ECONNREFUSED 127.0.0.1:4444
at Server.createSession <node_modules/leadfoot/Server.js:324:15>
at <node_modules/intern/lib/executors/Runner.js:191:22>
at retry <node_modules/intern/lib/util.js:845:13>
at <node_modules/dojo/Promise.ts:393:15>
at runCallbacks <node_modules/dojo/Promise.ts:11:11>
at <node_modules/dojo/Promise.ts:317:4>
at run <node_modules/dojo/Promise.ts:237:7>
at <node_modules/dojo/nextTick.ts:44:3>
at nextTickCallbackWith0Args <node.js:453:9>
at process._tickCallback <node.js:382:13>
Suite chrome 39 on MAC FAILED
Error: [POST http://localhost:4444/wd/hub/session] connect ECONNREFUSED 127.0.0.1:4444
at Server.createSession <node_modules/leadfoot/Server.js:324:15>
at <node_modules/intern/lib/executors/Runner.js:191:22>
at retry <node_modules/intern/lib/util.js:845:13>
at <node_modules/dojo/Promise.ts:393:15>
at runCallbacks <node_modules/dojo/Promise.ts:11:11>
at <node_modules/dojo/Promise.ts:317:4>
at run <node_modules/dojo/Promise.ts:237:7>
at <node_modules/dojo/nextTick.ts:44:3>
at nextTickCallbackWith0Args <node.js:453:9>
at process._tickCallback <node.js:382:13>
TOTAL: tested 0 platforms, 0/0 tests failed; fatal error occurred
Tunnel started
Suite chrome 39 on WINDOWS FAILED
Error: [POST http://localhost:4444/wd/hub/session] connect ECONNREFUSED 127.0.0.1:4444
at Server.createSession <node_modules/leadfoot/Server.js:324:15>
at <node_modules/intern/lib/executors/Runner.js:191:22>
at retry <node_modules/intern/lib/util.js:845:13>
at <node_modules/dojo/Promise.ts:393:15>
at runCallbacks <node_modules/dojo/Promise.ts:11:11>
at <node_modules/dojo/Promise.ts:317:4>
at run <node_modules/dojo/Promise.ts:237:7>
at <node_modules/dojo/nextTick.ts:44:3>
at nextTickCallbackWith0Args <node.js:453:9>
at process._tickCallback <node.js:382:13>
Suite chrome 39 on MAC FAILED
Error: [POST http://localhost:4444/wd/hub/session] connect ECONNREFUSED 127.0.0.1:4444
at Server.createSession <node_modules/leadfoot/Server.js:324:15>
at <node_modules/intern/lib/executors/Runner.js:191:22>
at retry <node_modules/intern/lib/util.js:845:13>
at <node_modules/dojo/Promise.ts:393:15>
at runCallbacks <node_modules/dojo/Promise.ts:11:11>
at <node_modules/dojo/Promise.ts:317:4>
at run <node_modules/dojo/Promise.ts:237:7>
at <node_modules/dojo/nextTick.ts:44:3>
at nextTickCallbackWith0Args <node.js:453:9>
at process._tickCallback <node.js:382:13>
TOTAL: tested 0 platforms, 0/0 tests failed; fatal error occurred
Error: Run failed due to one or more suite errors
at emitLocalCoverage <node_modules/intern/lib/executors/Executor.js:353:18>
at finishSuite <node_modules/intern/lib/executors/Executor.js:370:15>
at <node_modules/intern/lib/executors/Executor.js:378:8>
at <node_modules/intern/browser_modules/dojo/Promise.ts:393:15>
at runCallbacks <node_modules/intern/browser_modules/dojo/Promise.ts:11:11>
at <node_modules/intern/browser_modules/dojo/Promise.ts:317:4>
at run <node_modules/intern/browser_modules/dojo/Promise.ts:237:7>
at <node_modules/intern/browser_modules/dojo/nextTick.ts:44:3>
at nextTickCallbackWith0Args <node.js:453:9>
at process._tickCallback <node.js:382:13>
npm ERR! Test failed. See above for more details.
Error: Run failed due to one or more suite errors
at emitLocalCoverage <node_modules/intern/lib/executors/Executor.js:353:18>
at finishSuite <node_modules/intern/lib/executors/Executor.js:370:15>
at <node_modules/intern/lib/executors/Executor.js:378:8>
at <node_modules/intern/browser_modules/dojo/Promise.ts:393:15>
at runCallbacks <node_modules/intern/browser_modules/dojo/Promise.ts:11:11>
at <node_modules/intern/browser_modules/dojo/Promise.ts:317:4>
at run <node_modules/intern/browser_modules/dojo/Promise.ts:237:7>
at <node_modules/intern/browser_modules/dojo/nextTick.ts:44:3>
at nextTickCallbackWith0Args <node.js:453:9>
at process._tickCallback <node.js:382:13>
npm ERR! Test failed. See above for more details.
npm test returned exit code 1
npm test returned exit code 1
```
doesn't seem able to connect to the chromedriver