diff options
author | Thomas Müller <thomas.mueller@tmit.eu> | 2015-10-27 16:09:13 +0100 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2015-10-27 23:00:04 +0100 |
commit | b753e7631bd318a1f428d8925dec64693879fd0d (patch) | |
tree | f02f3ace2f9958f7068cd2a37ed52a8697e0d1f0 /tests/travis/before_install.sh | |
parent | 4d87276f4be55419189fb23d3c3c13f00c19f006 (diff) | |
download | nextcloud-server-b753e7631bd318a1f428d8925dec64693879fd0d.tar.gz nextcloud-server-b753e7631bd318a1f428d8925dec64693879fd0d.zip |
Enable DAV app testing on travis
Diffstat (limited to 'tests/travis/before_install.sh')
-rw-r--r-- | tests/travis/before_install.sh | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/tests/travis/before_install.sh b/tests/travis/before_install.sh new file mode 100644 index 00000000000..ee8c3a9862a --- /dev/null +++ b/tests/travis/before_install.sh @@ -0,0 +1,40 @@ +#!/bin/bash +# +# ownCloud +# +# @author Thomas Müller +# @copyright 2014 Thomas Müller thomas.mueller@tmit.eu +# + +set -e + +WORKDIR=$PWD +DB=$1 +echo "Work directory: $WORKDIR" +echo "Database: $DB" + +if [ "$DB" == "mysql" ] ; then + echo "Setting up mysql ..." + mysql -e 'create database oc_autotest;' + mysql -u root -e "CREATE USER 'oc_autotest'@'localhost' IDENTIFIED BY 'owncloud'"; + mysql -u root -e "grant all on oc_autotest.* to 'oc_autotest'@'localhost'"; + mysql -e "SELECT User FROM mysql.user;" +fi + +if [ "$DB" == "pgsql" ] ; then + createuser -U travis -s oc_autotest +fi + +#if [ "$DB" == "oracle" ] ; then +# if [ ! -f before_install_oracle.sh ]; then +# wget https://raw.githubusercontent.com/owncloud/administration/master/travis-ci/before_install_oracle.sh +# fi +# bash ./before_install_oracle.sh +#fi + +# +# copy custom php.ini settings +# +if [ $(phpenv version-name) != 'hhvm' ]; then + phpenv config-add tests/travis/custom.ini +fi |