Adjust .travis.yml to our repositories

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
pull/1/head
Lukas Reschke 7 years ago
parent 430ac31958
commit a6d0a5e5ab
No known key found for this signature in database
GPG Key ID: B9F6980CF6E759B1

@ -9,7 +9,7 @@ env:
- CORE_BRANCH=master - CORE_BRANCH=master
matrix: matrix:
- DB=sqlite - DB=sqlite
branches: branches:
only: only:
- master - master
@ -17,26 +17,48 @@ branches:
sudo: true sudo: true
before_install: before_install:
- wget https://raw.githubusercontent.com/owncloud/administration/master/travis-ci/before_install.sh - wget https://raw.githubusercontent.com/nextcloud/travis_ci/master/before_install.sh
- bash ./before_install.sh richdocuments $CORE_BRANCH $DB - bash ./before_install.sh $APP_NAME $CORE_BRANCH $DB
# Add some output debugging information
- cd ../server
- ./occ check
- ./occ status
- ./occ app:list
script: script:
# Test lint - cd apps/$APP_NAME/
- cd ../core/apps/richdocuments
- find . -name \*.php -exec php -l "{}" \; # Test the app
- sh -c "if [ '$JSTESTS' != '1' -a '$CODECHECK' = '1' ]; then find . -name \*.php -exec php -l \"{}\" \;; fi"
# Run phpunit tests - cd ../../
- cd tests - sh -c "if [ '$JSTESTS' != '1' -a '$CODECHECK' = '1' ]; then ./occ app:check-code $APP_NAME -c private -c strong-comparison; fi"
- phpunit --configuration phpunit.xml - sh -c "if [ '$JSTESTS' != '1' -a '$CODECHECK' = '2' ]; then ./occ app:check-code $APP_NAME -c deprecation; fi"
- cd apps/$APP_NAME/
# Create coverage report
- sh -c "if [ '$TRAVIS_PHP_VERSION' != 'hhvm' ]; then wget https://scrutinizer-ci.com/ocular.phar; fi" # Run phpunit tests
- sh -c "if [ '$TRAVIS_PHP_VERSION' != 'hhvm' ]; then php ocular.phar code-coverage:upload --format=php-clover clover.xml; fi" - cd tests/
- sh -c "if [ '$JSTESTS' != '1' -a '$CODECHECK' != '1' -a '$CODECHECK' != '2' ]; then phpunit --configuration phpunit.xml; fi"
# Create coverage report
- sh -c "if [ '$JSTESTS' != '1' -a '$CODECHECK' != '1' -a '$CODECHECK' != '2' ]; then wget https://scrutinizer-ci.com/ocular.phar; fi"
- sh -c "if [ '$JSTESTS' != '1' -a '$CODECHECK' != '1' -a '$CODECHECK' != '2' ]; then php ocular.phar code-coverage:upload --format=php-clover clover.xml; fi"
- cd ../
matrix:
matrix: matrix:
include: include:
- php: 5.6 - php: 5.6
env: DB=mysql env: DB=mysql
- php: 5.6 - php: 5.6
env: DB=pgsql env: DB=pgsql
- php: 5.6
env: DB=mysql;CODECHECK=1
- php: 5.6
env: DB=mysql;CODECHECK=2
- php: 5.6
env: DB=mysql;JSTESTS=1
allow_failures:
- env: DB=mysql;CODECHECK=2
fast_finish: true fast_finish: true

Loading…
Cancel
Save