From 878cb836f59afffca333b6d42e11c1bc0a4bc16f Mon Sep 17 00:00:00 2001 From: Andreas Fischer Date: Tue, 15 Oct 2013 22:44:49 +0200 Subject: [PATCH 1/3] [ticket/11920] Actually call travis/setup-mariadb.sh. PHPBB3-11920 --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index 03bc7fb945..ecaf43c4b5 100644 --- a/.travis.yml +++ b/.travis.yml @@ -14,6 +14,7 @@ env: before_script: - sh -c "if [ '$DB' = 'postgres' ]; then psql -c 'DROP DATABASE IF EXISTS phpbb_tests;' -U postgres; fi" - sh -c "if [ '$DB' = 'postgres' ]; then psql -c 'create database phpbb_tests;' -U postgres; fi" + - sh -c "if [ '$DB' = 'mariadb' ]; then travis/setup-mariadb.sh; fi" - sh -c "if [ '$DB' = 'mysql' -o '$DB' = 'mariadb' ]; then mysql -e 'create database IF NOT EXISTS phpbb_tests;'; fi" - sh -c "if [ '$TRAVIS_PHP_VERSION' = '5.2' ]; then pear install --force phpunit/DbUnit; phpenv rehash; fi" - cd phpBB From 0f64f0edc409ecea94159bb365b7f7efbd311195 Mon Sep 17 00:00:00 2001 From: Andreas Fischer Date: Wed, 16 Oct 2013 00:24:44 +0200 Subject: [PATCH 2/3] [ticket/11920] Manually purge mysql-common. PHPBB3-11920 --- travis/setup-mariadb.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/travis/setup-mariadb.sh b/travis/setup-mariadb.sh index 2e974da8eb..6742d27263 100755 --- a/travis/setup-mariadb.sh +++ b/travis/setup-mariadb.sh @@ -11,6 +11,9 @@ VERSION='5.5' # Operating system codename, e.g. "precise" OS_CODENAME=$(lsb_release --codename --short) +# Manually purge MySQL to remove conflicting files (e.g. /etc/mysql/my.cnf) +sudo apt-get purge -qq mysql-common + if ! which add-apt-repository > /dev/null then sudo apt-get update -qq From 5a481bb1763477edbacf530de7c64a729a796084 Mon Sep 17 00:00:00 2001 From: Andreas Fischer Date: Wed, 16 Oct 2013 00:25:07 +0200 Subject: [PATCH 3/3] [ticket/11920] Print MariaDB version after successful setup. PHPBB3-11920 --- travis/setup-mariadb.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/travis/setup-mariadb.sh b/travis/setup-mariadb.sh index 6742d27263..02520b1c2c 100755 --- a/travis/setup-mariadb.sh +++ b/travis/setup-mariadb.sh @@ -34,3 +34,5 @@ USE mysql; UPDATE user SET Password = PASSWORD('') where User = 'root'; FLUSH PRIVILEGES; " | mysql -u root -prootpasswd + +mysql --version