diff options
author | Bernhard Posselt <dev@bernhard-posselt.com> | 2016-03-26 22:26:01 +0100 |
---|---|---|
committer | Bernhard Posselt <dev@bernhard-posselt.com> | 2016-03-27 14:53:29 +0200 |
commit | 04c1c8d3bd216a2195668cb06797079802c4fe44 (patch) | |
tree | 6e8ca32f2be56788f362eba68faddc69c84a2dca /.travis.yml | |
parent | f2181c00552a0d79b9c6fac54fe416b8a5b307f4 (diff) |
add common makefile, make it possible to run tests and build package without installing global libs, enhance travis build file to also run php tests, add dev docs
fix indention
fix copyright
exclude gulpfile from appstore build
also generate coverage when phpunit exsits in path
remove breaking codecov from test
run codecov after success, use previous make package
run test suite instead of build
try without sudo
another try without sudo
switch from mariadb to mysql
mysql server seems to be present out of the box
Diffstat (limited to '.travis.yml')
-rw-r--r-- | .travis.yml | 84 |
1 files changed, 68 insertions, 16 deletions
diff --git a/.travis.yml b/.travis.yml index f67149a0..824f4d90 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,5 +1,14 @@ sudo: false -language: node_js +dist: trusty +language: php +php: + - 5.6 + - 7 +env: + global: + - CORE_BRANCH=stable9 + matrix: + - DB=pgsql branches: only: @@ -7,23 +16,66 @@ branches: - /^stable\d+(\.\d+)?$/ - /^v\d++(\.\d+)?+(\.\d+)?+(\.\d+)?$/ +matrix: + allow_failures: + - env: DB=pgsql CORE_BRANCH=master + include: + - php: 5.6 + env: DB=sqlite + - php: 5.6 + env: DB=mysql + - php: 5.6 + env: DB=pgsql CORE_BRANCH=master + fast_finish: true + before_install: - - export DISPLAY=:99.0 - - sh -e /etc/init.d/xvfb start + - export DISPLAY=:99.0 + - sh -e /etc/init.d/xvfb start + - nvm install 5.6 + - npm install -g npm@latest + - make dist + # install core + - cd ../ + - git clone https://github.com/owncloud/core.git --recursive --depth 1 -b $CORE_BRANCH owncloud + - mv contacts owncloud/apps/ + +before_script: + - if [[ "$DB" == 'pgsql' ]]; then createuser -U travis -s oc_autotest; fi + - if [[ "$DB" == 'mysql' ]]; then mysql -u root -e 'create database oc_autotest;'; fi + - if [[ "$DB" == 'mysql' ]]; then mysql -u root -e "CREATE USER 'oc_autotest'@'localhost' IDENTIFIED BY '';"; fi + - if [[ "$DB" == 'mysql' ]]; then mysql -u root -e "grant all on oc_autotest.* to 'oc_autotest'@'localhost';"; fi + # fill owncloud with default configs and enable contacts + - cd owncloud + - mkdir data + - ./occ maintenance:install --database-name oc_autotest --database-user oc_autotest --admin-user admin --admin-pass admin --database $DB --database-pass='' + - ./occ app:enable contacts + - ./occ background:cron # enable default cron + - php -S localhost:8080 & + - cd apps/contacts script: - - node_modules/.bin/bower install - - node_modules/.bin/gulp eslint - - node_modules/.bin/gulp - - npm test - - make appstore_package + - make test + +after_failure: + - cat ../../data/owncloud.log + +after_success: + # codecov has issues when not run exactly in the cloned folder on travis, so + # revert everything + - cd ../../../ + - mv owncloud/apps/contacts . + - cd contacts + - node_modules/codecov/bin/codecov deploy: - provider: releases - api_key: - secure: IBNQc4MsBqOc6bj2fD1PnMFfELFpP2GqpZjmBsqP43dWixo8vZzafg7JwlsfnuC0rfcOE/2NwHQl43d+37sXMbMl+ZXgz2ax/wOyLAS2PK/EQEDkzYOdI0E/8u2D7V7m9LlCQ8MOGSGmjYwFcDLzcmgU8AOWg4N85ktpOkaiVF1287Rr+wcRZ0o4/VTVvykYzfKDIBaACAX+EaXtpBtD0cTr1lFN4vKuUma2+iX+MyPVZcvIbCWv2bTzqXzfkT3NagZuFXcooXhvPGFoOb8AisxRSoVP48Vpt8ziG+7wDFlIrNe+fjNJxOEMDEP8cYljoUU6MaOxcm012s/CqHjWBuTI5MRAWlH4w9YJ/1BhFoSJOUb21401zp255puPZJ+Vq8i720F21xm7g7Vc/1NsEAwmTzLgaG8cnV98SonITVDuR4qIaMWpHwTMhap6sHMW7UfH4QnCKypo1mgITFdjM9ANYbcfF8GBfrK4MZtuw75AcLoytFia+KnAOO7OpC93eo6Czcqu6ILOBz1XNWZcFQJTrkLKkFslZLhSSrgPrTL4Py0zVmBurxdOmoZkDcxyKmk/1ggQmZKhh7OS1TGW/7tckscwMhukLwnQiXBCQJ7VWAJ/2eaolym1+fDbqJ4z8t9q2KEfZyqlYAL4VxPqQzxwO9O19ej1WtncvpFHlQw= - file: build/artifacts/appstore/contacts.tar.gz - skip_cleanup: true - on: - repo: owncloud/contacts - tags: true + provider: releases + api_key: + secure: IBNQc4MsBqOc6bj2fD1PnMFfELFpP2GqpZjmBsqP43dWixo8vZzafg7JwlsfnuC0rfcOE/2NwHQl43d+37sXMbMl+ZXgz2ax/wOyLAS2PK/EQEDkzYOdI0E/8u2D7V7m9LlCQ8MOGSGmjYwFcDLzcmgU8AOWg4N85ktpOkaiVF1287Rr+wcRZ0o4/VTVvykYzfKDIBaACAX+EaXtpBtD0cTr1lFN4vKuUma2+iX+MyPVZcvIbCWv2bTzqXzfkT3NagZuFXcooXhvPGFoOb8AisxRSoVP48Vpt8ziG+7wDFlIrNe+fjNJxOEMDEP8cYljoUU6MaOxcm012s/CqHjWBuTI5MRAWlH4w9YJ/1BhFoSJOUb21401zp255puPZJ+Vq8i720F21xm7g7Vc/1NsEAwmTzLgaG8cnV98SonITVDuR4qIaMWpHwTMhap6sHMW7UfH4QnCKypo1mgITFdjM9ANYbcfF8GBfrK4MZtuw75AcLoytFia+KnAOO7OpC93eo6Czcqu6ILOBz1XNWZcFQJTrkLKkFslZLhSSrgPrTL4Py0zVmBurxdOmoZkDcxyKmk/1ggQmZKhh7OS1TGW/7tckscwMhukLwnQiXBCQJ7VWAJ/2eaolym1+fDbqJ4z8t9q2KEfZyqlYAL4VxPqQzxwO9O19ej1WtncvpFHlQw= + file: build/artifacts/appstore/contacts.tar.gz + skip_cleanup: true + on: + repo: owncloud/contacts + tags: true + +addons: + firefox: "latest" |