Download and install the current unstable and two previous stable releases:
npm install -g mongodb-version-manager
export PATH="`m path`:$PATH"
m 3.0.x && npm test && mongod --version
m 2.6.x && npm test && mongod --version
m 2.4.x && npm test && mongod --version
- Use a
.travis.yml
like
language: node_js
node_js:
- "0.10"
env:
- MONGODB_VERSION=2.6.x
- MONGODB_VERSION=3.0.x
- MONGODB_VERSION=3.1.x
npm install --save-dev mongodb-version-manager
- update your package.json
"scripts": {
"pretest": "m ${MONGODB_VERSION}",
"test": "mocha",
"posttest": "m kill"
}
Now you'll have a sweet matrix build on travis
MIT