forked from doctrine/mongodb-odm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
38 lines (30 loc) · 1.19 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
language: php
php:
- 5.5
- 5.6
env:
global:
- DOCTRINE_MONGODB_SERVER=mongodb://localhost:27017
matrix:
- MONGO_VERSION=1.5.8
- MONGO_VERSION=stable
matrix:
include:
- php: 7.0
env: ADAPTER_VERSION="^1.0.0" MONGODB_VERSION=stable
services: mongodb
before_script:
- if [ "x${MONGO_VERSION}" != "x" ]; then yes '' | pecl -q install -f mongo-${MONGO_VERSION} && echo "extension=mongo.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`; fi
- sudo service mongodb stop
- sudo pip install mongo-orchestration
- sudo mongo-orchestration start
- curl -XPUT http://localhost:8889/v1/sharded_clusters/myCluster --data @tests/sharded.json | python -m json.tool
- composer self-update
- if [ "x${MONGODB_VERSION}" != "x" ]; then pecl install -f mongodb-${MONGODB_VERSION}; fi
- if [ "x${ADAPTER_VERSION}" != "x" ]; then composer require "alcaeus/mongo-php-adapter=${ADAPTER_VERSION}" --ignore-platform-reqs; fi
- composer install --dev
script:
- ./vendor/bin/phpunit --coverage-clover=coverage.clover
after_script:
- wget https://scrutinizer-ci.com/ocular.phar
- php ocular.phar code-coverage:upload --format=php-clover coverage.clover