-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
42 lines (35 loc) · 1.78 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
dist: focal
php:
- 8.1
services:
- mysql
before_script:
- LC_ALL=C.UTF-8 sudo add-apt-repository -y ppa:ondrej/php
# To make sure everything works properly, we need to load ffmpeg, a modern version
# of GD (that includes imagewebp functions) nad ffmpeg
- sudo apt-get update
- sudo apt-get install -y ffmpeg
- sudo apt-get install -y php$(phpenv version-name)-cli php$(phpenv version-name)-gd php$(phpenv version-name)-xml php$(phpenv version-name)-curl php$(phpenv version-name)-imagick
- sudo apt-get install -y php$(phpenv version-name)-zip php$(phpenv version-name)-mbstring php$(phpenv version-name)-mysql php$(phpenv version-name)-memcached
- sudo apt-get install -y php$(phpenv version-name)-memcache php$(phpenv version-name)-xdebug pngquant
# There's a need for a patch in order to make imagewebp work.
# The script we pulled this from includes a lot of debugging output
# https://travis-ci.community/t/how-to-enable-webp-image-format-support-in-php-7/3209/19
- php -v
- rm -f /home/travis/.phpenv/shims/php
- ln -s /usr/bin/php /home/travis/.phpenv/shims/php
- which php
- php -r "var_dump(function_exists('imagewebp'));"
- php -r "var_dump(gd_info());"
- /usr/bin/php -r "var_dump(function_exists('imagewebp'));"
- /usr/bin/php -r "var_dump(gd_info());"
# Initialize the composer stuff.
- composer install
- composer dump-autoload
# This file is brought in by a dependency, but is not compatible with the current version of PHP
- rm vendor/jms/serializer/src/Annotation/ReadOnly.php
script: XDEBUG_MODE=coverage vendor/bin/phpunit --configuration=phpunit.xml --coverage-clover=coverage.clover tests
after_script:
- tail coverage.clover
- vendor/bin/ocular code-coverage:upload --format=php-clover coverage.clover -v;