forked from briannesbitt/Carbon
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
113 lines (99 loc) · 3.96 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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
language: php
cache:
apt: true
directories:
- $HOME/.composer/cache
addons:
apt:
packages:
- language-pack-ar
- language-pack-fr
- language-pack-sr
- language-pack-zh-hans
- language-pack-zh-hant
env:
global:
- setup=basic
- coverage=false
- phpstan=false
- laravel=false
sudo: false
services:
- memcached
- mysql
before_install:
- if [[ $coverage = 'false' ]]; then phpenv config-rm xdebug.ini || true; fi
- if [[ $laravel = 'true' ]]; then echo "extension = memcached.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini; fi
- if [[ $laravel = 'true' ]]; then printf "\n" | pecl install -f redis; fi
- if [[ $laravel = 'true' ]]; then travis_retry composer self-update; fi
- if [[ $laravel = 'true' ]]; then mysql -e 'CREATE DATABASE forge;' && mysql -u root -e "CREATE USER 'forge'@'localhost';" && mysql -u root -e "GRANT ALL ON forge.* TO 'forge'@'localhost';"; fi
install:
- composer remove --no-update friendsofphp/php-cs-fixer
- composer remove --no-update phpmd/phpmd
- composer remove --no-update squizlabs/php_codesniffer
- if [[ $style_check != 'true' ]]; then travis_retry composer remove --no-update phpstan/phpstan phpmd/phpmd friendsofphp/php-cs-fixer --no-interaction --dev; fi
- if [[ $laravel != 'true' ]]; then travis_retry composer remove --no-update kylekatarnls/multi-tester --no-interaction --dev; fi
- if [[ $setup = 'nightly' ]]; then travis_retry composer update --prefer-dist --no-interaction --no-suggest --ignore-platform-reqs; fi
- if [[ $setup = 'basic' ]]; then travis_retry composer update --prefer-dist --no-interaction --no-suggest; fi
- if [[ $setup = 'stable' ]]; then travis_retry composer update --prefer-dist --no-interaction --no-suggest --prefer-stable; fi
- |
if [[ $setup = 'lowest' ]]; then
travis_retry composer update --prefer-dist --no-interaction --no-suggest --prefer-stable --prefer-lowest
fi
script:
- if [[ $laravel != 'true' && $style_check != 'true' && $coverage = 'true' ]]; then vendor/bin/phpunit --verbose --coverage-clover=coverage.xml --coverage-text; fi
- if [[ $laravel != 'true' && $style_check != 'true' && $coverage != 'true' ]]; then vendor/bin/phpunit --verbose; fi
- if [[ $laravel != 'true' && $style_check = 'true' ]]; then composer style-check; fi
- if [[ $laravel = 'true' ]]; then vendor/bin/multi-tester; fi
after_success:
- if [[ $coverage = 'true' ]]; then bash <(curl -s https://codecov.io/bash); fi
branches:
only:
- gh-pages
- /.*/
matrix:
include:
- php: 7.1.8
- php: 7.1.28
- php: 7.1
- php: 7.1
env: setup=lowest
- php: 7.1
env: setup=stable
- php: 7.2.0
- php: 7.2.15
- php: 7.2
- php: 7.2
env: setup=lowest
- php: 7.2
env: setup=stable
- php: 7.3.0
- php: 7.3.5
- php: 7.3
- php: 7.3
env: setup=lowest
- php: 7.3
env:
- setup=stable
- coverage=true
- php: 7.4
env: setup=lowest
- php: 7.4
- php: nightly
env: setup=nightly
- php: 7.3
env:
- setup=stable
- laravel=true
- php: 7.3
env:
- setup=stable
- style_check=true
allow_failures:
- php: 7.3
env:
- setup=stable
- laravel=true
notifications:
slack:
secure: mdZBxjp18TYD4hOXKrj2mayveaUBj2fcgiVb1LOv1fiuonzhNwT5I5n795BNGpl1z76I8ZzD3MICbvigXs8QGMBkTnCriSEZNuyQUlAR972q+h02HmKM/j0d90S3tGbPh6PFGh0oo7ZCt0TAlHtNTGL0uyOwzJ26A+Sa5zA8HzN+y44KXTyMYRE/RXDkKB8460W+UFOVXsFw3pdXqeW6CbQY4A8hR8F0veBThfqrE/qXtmQ0MR97uuaDQDbJAiJuVe3DzIOcAdYwuqYbm3sgsomqsXONX7LyrrqXPguNDyM7XwkZUP6t9Nqvxz94HIJkYWASFNgOyysxOYqhgtAG7/xkT77D63IzxcsxLtfNSzOJwaP7xE3YHog082MR0ywdpZpjklmDdPhhiDfGaGRSHGJCqEMcW4QjFibLm3pnvxXoeTyY4Zx0hkCRqDlTYq9IMX6i3fVF4dZ+egOSJrd9BDXlnkyNy2C3z/5Ee6hfVoD53FT4l8zvRc+ip2tFQOzE1O81o8OYHOsF4DfcE0u1B/+ZeYihuFbJ8DMIBv8bUlZ76sQLQD0FAPzeKURDB2lTlUFODUH8ewPEuGbH6Bbao5bFoeWKvC6xTCuanpeU1xwJrzSvzMljqcEyZmOoqST776wCwS/qjY9yh8344VTZYHqGVY/L5DxjTbvSKpyHj2k=