Fix whitespace trimming in headings
[mediawiki.git] / .travis.yml
bloba28dac0ff0e47246af3b4e5ad1f3dd7e326de948
1 # Travis CI build configuration for MediaWiki
2 # <https://travis-ci.org/wikimedia/mediawiki-core>
4 # The Wikimedia Foundation uses a self-hosted Jenkins instance to run unit
5 # tests, but it tests code against the version of PHP that is deployed on
6 # Wikimedia's production cluster. This Travis CI configuration is designed to
7 # complement that setup by testing MediaWiki on travis
9 language: php
12 # Use fast containers instead of the slower sudo-enabled VMs:
13 sudo: false
14 # Use Ubuntu 14 Trusty (not Ubuntu 12 Precise)
15 # <https://docs.travis-ci.com/user/reference/trusty/>
16 # - Required in order to use HHVM 3.6 or higher.
17 # - Required for non-buggy xml library for XmlTypeCheck/UploadBaseTest (T75176).
18 dist: trusty
20 matrix:
21   fast_finish: true
22   include:
23     # On Trusty, mysql user 'travis' doesn't have create database rights
24     # Postgres has no user called 'root'.
25     - env: dbtype=mysql dbuser=root
26       php: 5.5
27     - env: dbtype=postgres dbuser=travis
28       php: 5.5
29     # https://docs.travis-ci.com/user/languages/php#HHVM-versions
30     - env: dbtype=mysql dbuser=root
31       php: hhvm-3.18
32     - env: dbtype=mysql dbuser=root
33       php: hhvm-3.21
34     - env: dbtype=mysql dbuser=root
35       php: hhvm-3.24
36     - env: dbtype=mysql dbuser=root
37       php: 7
38     - env: dbtype=mysql dbuser=root
39       php: 7.1
40     - env: dbtype=mysql dbuser=root
41       php: 7.2
43 services:
44   - mysql
46 branches:
47   # Test changes in master and arbitrary Travis CI branches only.
48   # The latter allows developers to enable Travis CI in their GitHub fork of
49   # wikimedia/mediawiki and then push changes for testing to branches like
50   # "travis-ci/test-this-awesome-change".
51   only:
52     - master
53     - /^travis-ci\/.*$/
55 addons:
56   apt:
57     packages:
58     - djvulibre-bin
59     - tidy
61 before_script:
62   - composer install --prefer-source --quiet --no-interaction
63   - if [ "$dbtype" = postgres ]; then psql -c "CREATE DATABASE traviswiki WITH OWNER travis;" -U postgres; fi
64   - >
65       php maintenance/install.php traviswiki admin
66       --pass travis
67       --dbtype "$dbtype"
68       --dbname traviswiki
69       --dbuser "$dbuser"
70       --dbpass ""
71       --scriptpath "/w"
72   - echo -en "\n\nrequire_once __DIR__ . '/includes/DevelopmentSettings.php';\n" >> ./LocalSettings.php
73   - php -l ./LocalSettings.php
75 script:
76   - php tests/phpunit/phpunit.php
78 notifications:
79   email: false
80   irc:
81     channels:
82       - "chat.freenode.net#mediawiki-feed"
83     on_success: change
84     on_failure: change
85     skip_join: true