Skip to content

Commit

Permalink
Improve the Travis configuration
Browse files Browse the repository at this point in the history
- add testing against newer PHP versions
- add testing on lowest composer deps
- switch to the faster container-based infrastructure
- keep the composer cache between builds
- use the mongo driver shipped by Travis for most builds (it is much
  newer)
  • Loading branch information
stof committed Apr 15, 2015
1 parent 1ac417f commit b35a47e
Showing 1 changed file with 22 additions and 6 deletions.
28 changes: 22 additions & 6 deletions .travis.yml
Expand Up @@ -3,14 +3,30 @@ language: php
php:
- 5.3
- 5.4
- 5.5
- 5.6

env:
- MONGO_VERSION=1.2.12
- MONGO_VERSION=1.3.3
matrix:
include:
- php: 5.3
env: COMPOSER_FLAGS='--prefer-lowest --prefer-stable'
- php: 5.6
env: MONGO_VERSION=1.2.12
- php: 5.6
env: MONGO_VERSION=1.3.3

sudo: false

cache:
directories:
- $HOME/.composer/cache

services: mongodb

before_script:
- pecl -q install -f mongo-${MONGO_VERSION} && echo "extension=mongo.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
- composer install --dev
before_install:
- if [ "$MONGO_VERSION" != "" ]; then pecl -q install -f mongo-${MONGO_VERSION}; fi # Use a specific driver version when needed rather than the one shipped by Travis
- echo "extension=mongo.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`

install:
- composer update $COMPOSER_FLAGS

0 comments on commit b35a47e

Please sign in to comment.