-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
37 lines (27 loc) · 931 Bytes
/
.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
language: php
sudo: false
php:
- 5.6
- 7.0
- 7.1
env:
matrix:
- DB=mysql db_class='Cake\Database\Driver\Mysql' db_dsn='mysql:host=0.0.0.0;dbname=test' db_database='test' db_username='travis' db_password=''
global:
- DEFAULT=1
matrix:
fast_finish: true
# include:
# - php: 7.0
# env: PHPCS=1 DEFAULT=0
before_script:
- composer install --prefer-dist --no-interaction
- sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'CREATE DATABASE test;'; fi"
- cp phpunit.xml.dist phpunit.xml
- cp config/app.default.php config/app.php
script:
- sh -c "if [ '$DEFAULT' = '1' ]; then phpunit; fi"
- sh -c "if [ '$PHPCS' = '1' ]; then vendor/bin/phpcs --config-set installed_paths vendor/cakephp/cakephp-codesniffer; fi"
- sh -c "if [ '$PHPCS' = '1' ]; then vendor/bin/phpcs -p --extensions=php --standard=CakePHP --ignore=vendor --ignore=config/Migrations -v . ; fi"
notifications:
email: false