]> git.agnieray.net Git - galette.git/blob - .travis.yml
Drop empty bin directory from vendor
[galette.git] / .travis.yml
1 sudo: false
2 services:
3 - postgresql
4 - mysql
5 before_script:
6 - if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.2" ]]; then composer self-update --rollback; fi
7 - ./bin/install_deps
8 - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'DROP DATABASE IF EXISTS galette_tests;' -U postgres; fi"
9 - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'create database galette_tests;' -U postgres; fi"
10 - sh -c "if [ '$DB' = 'pgsql' ]; then psql -d galette_tests -a -f galette/install/scripts/pgsql.sql -U postgres; fi"
11 - sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'create database IF NOT EXISTS galette_tests;'; fi"
12 - sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'use galette_tests; source galette/install/scripts/mysql.sql;'; fi"
13 - if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.4" && $DB == "mysql" ]]; then cd galette && composer require squizlabs/php_codesniffer && composer require maglnet/composer-require-checker && cd ..; fi
14
15 script:
16 - if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.4" && $DB == "mysql" ]]; then galette/vendor/bin/phpcs -n -p --ignore=galette_tcpdf_config.php --standard=phpcs-rules.xml galette/lib/ tests/TestsBootstrap.php tests/Galette tests/plugins galette/webroot/index.php galette/includes/fields_defs/ galette/includes/smarty_plugins/ galette/includes/functions.inc.php galette/includes/galette.inc.php galette/includes/dependencies.php galette/includes/main.inc.php; fi
17 - if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.4" && $DB == "mysql" ]]; then cd galette && vendor/bin/composer-require-checker check --config-file=../.composer-require-checker.config.json && cd ..; fi
18 - php galette/vendor/bin/atoum -mcn 1 -bf tests/TestsBootstrap.php -c tests/clover.php -d tests/Galette/
19 - php galette/cron/reminder.php
20
21 after_script:
22 ## Scrutinizer
23 - wget https://scrutinizer-ci.com/ocular.phar
24 - if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.4" && $DB == "pgsql" ]]; then php ocular.phar code-coverage:upload --format=php-clover tests/clover.xml; fi
25
26 language: php
27
28 php:
29 - 7.4
30 # - 7.3
31 - 7.2
32 # - nightly
33
34 matrix:
35 allow_failures:
36 - php: nightly
37
38 env:
39 - DB=pgsql
40 - DB=mysql
41
42 notifications:
43 webhooks:
44 urls:
45 - "https://scalar.vector.im/api/neb/services/hooks/dHJhdmlzLWNpLyU0MGpvaGFuLmN3aSUzQW1hdHJpeC5vcmcvJTIxUklBdnZwRFBnQkl1ZlBva0JDJTNBbWF0cml4Lm9yZw"
46 on_success: change # always|never|change
47 on_failure: always
48 on_start: never