language: node_js
sudo: false
node_js:
    - "8"
    - "7"
    - "6"
    - "5"
    - "4"
services:
    - mongodb
script:
    - npm run lint
    - npm run test
addons:
    apt:
        sources:
            - mongodb-3.0-precise
        packages:
            - mongodb-org-server

language: node_js
sudo: false
node_js:
    - "8"
    - "7"
    - "6"
    - "5"
    - "4"
services:
    - mongodb
env:
    - MONGOOSE_VERSION="4"
    - MONGOOSE_VERSION="5"
install:
    - npm install
    - npm install mongoose@${MONGOOSE_VERSION}
script:
    - npm run lint
    - npm run test
addons:
    apt:
        sources:
            - mongodb-3.0-precise
        packages:
            - mongodb-org-server

Test both Mongoose@4 and Mongoose@5
Test both Mongoose@4 and Mongoose@5
