-
Notifications
You must be signed in to change notification settings - Fork 364
improve and speedup circle ci setup #164
improve and speedup circle ci setup #164
Conversation
Let's do it! |
Thanks @DominikGuzei ! |
} else { | ||
// DEV mode -> watch | ||
startTestApp(startChimpWatch, { | ||
MONGO_URL: 'mongodb://localhost:3001/chimp_db' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line is causing errors for me when I run ./tests/acceptance_run
or ./tests/acceptance_watch
. If I comment it out, the tests run fine.
Any ideas?
W20160802-13:09:00.524(-7)? (STDERR)
W20160802-13:09:00.525(-7)? (STDERR) /Users/noah/.meteor/packages/meteor-tool/.1.3.4_4.l7vwzg++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/server-lib/node_modules/fibers/future.js:313
W20160802-13:09:00.525(-7)? (STDERR) throw(ex);
W20160802-13:09:00.525(-7)? (STDERR) ^
W20160802-13:09:00.676(-7)? (STDERR) Error: failed to connect to [localhost:3001]
W20160802-13:09:00.676(-7)? (STDERR) at Object.Future.wait (/Users/noah/.meteor/packages/meteor-tool/.1.3.4_4.l7vwzg++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/server-lib/node_modules/fibers/future.js:449:15)
W20160802-13:09:00.676(-7)? (STDERR) at new MongoConnection (packages/mongo/mongo_driver.js:213:27)
W20160802-13:09:00.677(-7)? (STDERR) at new MongoInternals.RemoteCollectionDriver (packages/mongo/remote_collection_driver.js:4:16)
W20160802-13:09:00.677(-7)? (STDERR) at Object.<anonymous> (packages/mongo/remote_collection_driver.js:38:10)
W20160802-13:09:00.678(-7)? (STDERR) at Object.defaultRemoteCollectionDriver (packages/underscore/underscore.js:750:1)
W20160802-13:09:00.678(-7)? (STDERR) at new Mongo.Collection (packages/mongo/collection.js:103:40)
W20160802-13:09:00.678(-7)? (STDERR) at AccountsServer.AccountsCommon (packages/accounts-base/accounts_common.js:23:18)
W20160802-13:09:00.678(-7)? (STDERR) at new AccountsServer (packages/accounts-base/accounts_server.js:18:5)
W20160802-13:09:00.678(-7)? (STDERR) at meteorInstall.node_modules.meteor.accounts-base.server_main.js (packages/accounts-base/server_main.js:9:12)
W20160802-13:09:00.679(-7)? (STDERR) at fileEvaluate (packages/modules-runtime/.npm/package/node_modules/install/install.js:153:1)
W20160802-13:09:00.679(-7)? (STDERR) - - - - -
W20160802-13:09:00.679(-7)? (STDERR) at [object Object].<anonymous> (/Users/noah/.meteor/packages/npm-mongo/.1.4.45.1n9eimd++os+web.browser+web.cordova/npm/node_modules/mongodb/lib/mongodb/connection/server.js:556:74)
W20160802-13:09:00.679(-7)? (STDERR) at [object Object].emit (events.js:106:17)
W20160802-13:09:00.679(-7)? (STDERR) at [object Object].<anonymous> (/Users/noah/.meteor/packages/npm-mongo/.1.4.45.1n9eimd++os+web.browser+web.cordova/npm/node_modules/mongodb/lib/mongodb/connection/connection_pool.js:156:15)
W20160802-13:09:00.680(-7)? (STDERR) at [object Object].emit (events.js:98:17)
W20160802-13:09:00.680(-7)? (STDERR) at Socket.<anonymous> (/Users/noah/.meteor/packages/npm-mongo/.1.4.45.1n9eimd++os+web.browser+web.cordova/npm/node_modules/mongodb/lib/mongodb/connection/connection.js:534:10)
W20160802-13:09:00.680(-7)? (STDERR) at Socket.emit (events.js:95:17)
W20160802-13:09:00.680(-7)? (STDERR) at net.js:441:14
W20160802-13:09:00.681(-7)? (STDERR) at process._tickCallback (node.js:458:13)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When you run the tests locally on your machine, you have to start the "normal" app first – this is done because otherwise the testing environment would override your local DB everytime. What we do here is this: the normal app is started and then the testing app uses the special Meteor MongoDB server to setup a chimp_db
on the same mongo instance. This simplifies the setup because you do not need to have a standalone mongo installed and setup correctly locally.
So do this:
meteor
wait until the app runs, then in a different terminal:
./tests/acceptance_run
or ./tests/acceptance_watch
Looking at the output of CircleCI, it looks like this isn't running any tests. Am I missing something? https://circleci.com/gh/meteor/todos/271
|
Fixes the CircleCi tests and improves performance by caching all important parts of the application and test dependencies.
The chimp script is moved outside of the
package.json
file because i ran into several issues with chimp and Node.js 0.10.x that Meteor is using. So the problem is that if you run Node viameteor npm run
you are forced to the Meteor node version. if you run it from outside you can have Node.js 5+ installed globally and basically run Meteor and chimp with different versions.Here are the related Github issues and discussions:
xolvio/chimp#204
xolvio/chimp#201
Bottom line: Meteor really has to upgrade to use up-to-date Node.js versions soon. Until then, we cannot use the
package.json
with chimp.This also removes the unit and app-tests from the CircleCi run since they fail for me. Probably i should also fix these but i do not have enough time at the moment 😢