This repository was archived by the owner on Jan 2, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy path.travis.yml
More file actions
59 lines (53 loc) · 1.81 KB
/
.travis.yml
File metadata and controls
59 lines (53 loc) · 1.81 KB
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
language: php
branches:
only:
- master
jobs:
include:
-
php: "7.1"
-
php: "7.2"
env: lint=1
-
php: "7.3"
env: coverage=1
-
php: "7.3"
env: deps=low
cache:
directories:
- $HOME/.composer/cache
before_script:
- if [[ $coverage != '1' ]]; then
phpenv config-rm xdebug.ini || echo "xdebug not available";
fi
install:
- if [[ $deps = 'low' ]]; then
composer update --prefer-dist --no-progress --no-suggest --prefer-stable --prefer-lowest --ansi;
if [[ $TRAVIS_EVENT_TYPE = 'cron' ]]; then
composer require drupal/core:8.8.x-dev --update-with-all-dependencies --prefer-lowest --prefer-dist --no-progress --no-suggest --ansi;
fi
else
composer update --prefer-dist --no-progress --no-suggest --ansi;
if [[ $TRAVIS_EVENT_TYPE = 'cron' ]]; then
composer require drupal/core:8.8.x-dev --update-with-all-dependencies --prefer-dist --no-progress --no-suggest --ansi;
fi
fi
script:
- if [[ $coverage = '1' ]]; then
vendor/bin/phpunit --dump-xdebug-filter xdebug_filter.php;
vendor/bin/phpunit --coverage-clover=coverage.clover --prepend=xdebug_filter.php;
else
vendor/bin/phpunit --no-coverage;
fi
- if [[ $coverage = '1' ]]; then
wget https://scrutinizer-ci.com/ocular.phar;
php ocular.phar code-coverage:upload --format=php-clover --revision=$TRAVIS_PULL_REQUEST_SHA coverage.clover;
fi
- if [[ $lint = '1' ]]; then
vendor/bin/php-cs-fixer fix --dry-run --diff --no-ansi;
fi
- if [[ $lint = '1' ]]; then
vendor/bin/phpstan analyse -c quality-analysis/phpstan/phpstan.neon;
fi