dist: trusty sudo: required language: php php: - 7.2 - 7.3 - 7.4snapshot services: - mysql - postgresql - docker addons: apt: packages: - alien - libaio1 cache: directories: - docker apt: true env: global: - CORE_BRANCH=master - APP_NAME=notifications matrix: - DB=sqlite branches: only: - master - /^stable\d+(\.\d+)?$/ before_install: - wget https://raw.githubusercontent.com/nextcloud/travis_ci/master/before_install.sh - travis_wait 20 . ./before_install.sh $APP_NAME $CORE_BRANCH $DB - sh -c "if [ -f ../server/data/nextcloud.log ]; then cat ../server/data/nextcloud.log; fi" # Add some output debugging information - cd ../server - ./occ check - ./occ status - ./occ app:list - ./occ app:enable $APP_NAME - ./occ app:list # Setup behat for integration tests - cd apps/$APP_NAME/ - cd tests/Integration/ - sh -c "if [ '$INTEGRATION' = '1' ]; then composer install; fi" - cd ../../ script: - composer install # Run phpunit tests - cd tests/Unit - sh -c "if [ '$INTEGRATION' != '1' -a '$JSTESTS' != '1' -a '$CODECHECK' != '1' -a '$CODECHECK' != '2' ]; then ../../vendor/bin/phpunit --configuration phpunit.xml; fi" - cd ../.. # Integration tests - cd tests/Integration - sh -c "if [ '$INTEGRATION' = '1' ]; then bash run.sh; fi" - cd ../.. matrix: include: - php: 7.3 env: DB=mysql - php: 7.3 env: DB=pgsql - php: 7.3 env: DB=oracle - php: 7.2 env: DB=mysql;INTEGRATION=1 allow_failures: - env: DB=mysql;CODECHECK=2 fast_finish: true