/
.travis.yml
42 lines (32 loc) · 1.06 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
39
40
41
42
language: php
sudo: false
dist: precise
notifications:
email:
on_success: never
on_failure: change
branches:
only:
- master
- develop
php:
- 7.2
- 7.1
- 5.6
- 5.4
- 5.3
env:
- WP_VERSION=latest WP_MULTISITE=0
- WP_VERSION=latest WP_MULTISITE=1
before_script:
- bash tests/bin/install.sh gravityview_test root '' localhost $WP_VERSION
- bash tests/bin/travis.sh before
- mkdir -p /tmp/wordpress-tests-lib/data/themedir1
- if [[ $TRAVIS_PHP_VERSION = '7.2' && $WP_VERSION = 'latest' && $WP_MULTISITE = '0' ]]; then DO_COVERAGE=1; else DO_COVERAGE=0; fi
script:
- if [[ $DO_COVERAGE = '1' ]]; then vendor/bin/phpunit -c phpunit.xml.dist; else vendor/bin/phpunit -c phpunit.xml.dist --no-coverage; fi
after_script:
- if [[ $DO_COVERAGE = '1' ]]; then wget https://scrutinizer-ci.com/ocular.phar; fi
- if [[ $DO_COVERAGE = '1' ]]; then php ocular.phar code-coverage:upload --format=php-clover /tmp/clover.xml; fi
after_success:
- if [[ $DO_COVERAGE = '1' ]]; then travis_retry php vendor/bin/coveralls -v --exclude-no-stmt; fi