2016-02-21 16:55:02 +03:00
|
|
|
sudo: required
|
|
|
|
dist: trusty
|
2013-07-20 02:06:15 +04:00
|
|
|
language: php
|
|
|
|
php:
|
2015-01-23 18:41:50 +03:00
|
|
|
- 5.6
|
2016-01-06 23:42:30 +03:00
|
|
|
- 7
|
2015-08-07 16:34:46 +03:00
|
|
|
env:
|
|
|
|
global:
|
2016-03-26 16:54:31 +03:00
|
|
|
- CORE_BRANCH=stable9
|
2015-08-07 16:34:46 +03:00
|
|
|
matrix:
|
|
|
|
- DB=pgsql
|
2015-01-23 17:51:27 +03:00
|
|
|
|
|
|
|
matrix:
|
2015-04-30 15:38:03 +03:00
|
|
|
allow_failures:
|
2016-01-06 23:42:30 +03:00
|
|
|
- env: DB=pgsql CORE_BRANCH=master
|
2015-04-30 15:38:03 +03:00
|
|
|
include:
|
2016-02-21 16:55:02 +03:00
|
|
|
- php: 5.6
|
2015-04-30 15:38:03 +03:00
|
|
|
env: DB=sqlite
|
2016-02-21 16:55:02 +03:00
|
|
|
- php: 5.6
|
2015-08-07 16:24:16 +03:00
|
|
|
env: DB=mysql
|
2016-02-21 16:55:02 +03:00
|
|
|
- php: 5.6
|
2016-03-26 18:58:52 +03:00
|
|
|
env: DB=pgsql CORE_BRANCH=master
|
2015-04-30 15:40:23 +03:00
|
|
|
fast_finish: true
|
2013-07-06 03:05:14 +04:00
|
|
|
|
2013-07-19 21:34:51 +04:00
|
|
|
before_install:
|
2016-02-21 16:55:02 +03:00
|
|
|
- export DISPLAY=:99.0
|
|
|
|
- sh -e /etc/init.d/xvfb start
|
2014-10-21 18:45:36 +04:00
|
|
|
- sudo apt-get update
|
2016-02-21 17:34:54 +03:00
|
|
|
- sudo apt-get -y install python3-setuptools firefox mariadb-server
|
2016-02-21 17:50:43 +03:00
|
|
|
- sudo easy_install3 requests ocdev
|
2016-03-26 17:21:52 +03:00
|
|
|
- nvm install 5.6
|
2016-02-13 15:11:20 +03:00
|
|
|
- npm install -g npm@latest
|
2016-03-26 21:00:28 +03:00
|
|
|
- make dist
|
|
|
|
- wget https://scrutinizer-ci.com/ocular.phar
|
2016-02-14 15:06:57 +03:00
|
|
|
# install core
|
2016-03-26 18:35:43 +03:00
|
|
|
- cd ../
|
2015-08-07 16:01:56 +03:00
|
|
|
- ocdev setup core --dir owncloud --branch $CORE_BRANCH --no-history
|
2014-10-21 18:45:36 +04:00
|
|
|
- mv news owncloud/apps/
|
2014-05-16 00:55:10 +04:00
|
|
|
|
2015-03-21 14:49:11 +03:00
|
|
|
before_script:
|
2014-10-21 18:45:36 +04:00
|
|
|
- createuser -U travis -s oc_autotest
|
2016-02-21 17:40:06 +03:00
|
|
|
- mysql -u root -e 'create database oc_autotest;'
|
2015-04-30 15:05:17 +03:00
|
|
|
- mysql -u root -e "CREATE USER 'oc_autotest'@'localhost' IDENTIFIED BY '';"
|
2014-10-21 18:45:36 +04:00
|
|
|
- mysql -u root -e "grant all on oc_autotest.* to 'oc_autotest'@'localhost';"
|
|
|
|
# fill owncloud with default configs and enable news
|
|
|
|
- cd owncloud
|
2015-01-15 18:14:36 +03:00
|
|
|
- mkdir data
|
2015-04-30 13:59:08 +03:00
|
|
|
- ./occ maintenance:install --database-name oc_autotest --database-user oc_autotest --admin-user admin --admin-pass admin --database $DB --database-pass=''
|
2015-04-29 12:08:30 +03:00
|
|
|
- ./occ app:enable news
|
2015-08-07 15:41:51 +03:00
|
|
|
- ./occ background:cron # enable default cron
|
2016-02-21 17:12:09 +03:00
|
|
|
- ocdev server &
|
2016-02-14 15:06:57 +03:00
|
|
|
- cd apps/news
|
2013-07-06 12:28:24 +04:00
|
|
|
|
2013-07-06 12:40:25 +04:00
|
|
|
script:
|
2014-11-06 12:17:47 +03:00
|
|
|
# unit tests
|
2016-02-13 21:04:57 +03:00
|
|
|
- phpunit -c phpunit.xml --coverage-clover coverage.clover
|
2016-02-12 00:36:29 +03:00
|
|
|
- phpunit -c phpunit.integration.xml
|
2016-02-13 21:04:57 +03:00
|
|
|
- php ocular.phar code-coverage:upload --format=php-clover coverage.clover
|
2016-02-12 00:36:29 +03:00
|
|
|
- cd js
|
|
|
|
- gulp karma
|
2014-10-21 18:45:36 +04:00
|
|
|
# acceptance tests
|
2016-02-21 17:19:52 +03:00
|
|
|
#- webdriver-manager update
|
2014-10-21 18:45:36 +04:00
|
|
|
# debug section to check what went wrong
|
2016-03-26 21:00:28 +03:00
|
|
|
- cd ..
|
|
|
|
- sudo cat ../../data/owncloud.log
|
|
|
|
|
|
|
|
deploy:
|
|
|
|
provider: releases
|
|
|
|
skip_cleanup: true
|
|
|
|
api_key:
|
|
|
|
secure: ds45weacZfcM1kPEFMSBogc3KRxdb77O4V6OfDCWEZTvdCgq5AWY21Rc4fCRL+UYPGtHAWykL96xgoii81uuKEK+eqyJtOlrp53EGHsyYJLkSPg8Yjccj9W5WuAUymiuP/vilB8+L1HqpUQW9bXzlYbI/AICYAIQzv5UN4+sXKA=
|
|
|
|
file: 'build/artifacts/source/news.tar.gz'
|
|
|
|
on:
|
|
|
|
repo: owncloud/news
|
2016-03-26 21:24:58 +03:00
|
|
|
tags: true
|