diff options
author | Daniel Schaal <daniel@schaal.email> | 2017-06-06 18:20:20 +0200 |
---|---|---|
committer | Bernhard Posselt <BernhardPosselt@users.noreply.github.com> | 2017-06-06 18:20:20 +0200 |
commit | b7f20c0f36dd6e0ed65ca93fcec44aa23f2fa203 (patch) | |
tree | 8882a0a91cce88683279b9030f126c303da5e7bb /.travis.yml | |
parent | f18aef805e60d3c8c00f4aff0a5c633052e72e34 (diff) |
Fix travis build (#178)
* Use stable12 branch for travis
* Shorten db indices to max 27 characters to satisfy app:check-code
* Use precise container, downgrade to psql 9.4
* Create psql role
* Fix ContentController test
* Fix PageController and StatusService tests
* Use OCP\IDBConnection, OCP\IDb was removed
* Extend IntegrationTest from \Test\Testcase, use loginAsUser to login
* Require phpunit 5, nextcloud tests not compatible with phpunit 6
Change tests to use phpunit from vendor directory
Diffstat (limited to '.travis.yml')
-rw-r--r-- | .travis.yml | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/.travis.yml b/.travis.yml index 565da4cd1..66f0b0ffd 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,4 +1,5 @@ sudo: false +dist: precise language: php php: - 5.6 @@ -7,7 +8,7 @@ php: env: global: - - CORE_BRANCH=stable11 + - CORE_BRANCH=stable12 matrix: - DB=pgsql @@ -37,14 +38,15 @@ before_install: - mv news nextcloud/apps/ before_script: - - if [[ "$DB" == 'pgsql' ]]; then psql -c 'create database oc_autotest;' -U postgres; fi + - if [[ "$DB" == 'pgsql' ]]; then psql -c "CREATE ROLE oc_autotest LOGIN PASSWORD 'oc_autotest'" -U postgres; fi + - if [[ "$DB" == 'pgsql' ]]; then psql -c "CREATE DATABASE oc_autotest OWNER oc_autotest;" -U postgres; 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 "CREATE USER 'oc_autotest'@'localhost' IDENTIFIED BY 'oc_autotest';"; fi - if [[ "$DB" == 'mysql' ]]; then mysql -u root -e "GRANT ALL ON oc_autotest.* TO 'oc_autotest'@'localhost';"; fi # fill nextcloud with default configs and enable news - cd nextcloud - mkdir data - - ./occ maintenance:install --database-name oc_autotest --database-user oc_autotest --admin-user admin --admin-pass admin --database $DB --database-pass='' + - ./occ maintenance:install --database-name oc_autotest --database-user oc_autotest --admin-user admin --admin-pass admin --database $DB --database-pass="oc_autotest" - ./occ app:enable news - ./occ app:check-code news - ./occ background:cron # enable default cron @@ -59,8 +61,7 @@ after_failure: addons: firefox: "latest" - postgresql: "9.5" + postgresql: "9.4" services: - - mysql - - postgresql + - mysql
\ No newline at end of file |