summaryrefslogtreecommitdiff
path: root/storage/mroonga/tools/travis/script.sh
diff options
context:
space:
mode:
authorJan Lindström <jan.lindstrom@mariadb.com>2015-06-24 07:16:08 +0300
committerJan Lindström <jan.lindstrom@mariadb.com>2015-06-24 07:16:08 +0300
commit2e4984c185ddcd2da789017cd147338846ff409a (patch)
tree0293831900c860600efbaa747ea886d9d1cbf5bd /storage/mroonga/tools/travis/script.sh
parent792b53e80806df893ee62c9a1c1bd117114c8c6d (diff)
parenta6087e7dc1ef3561d8189c8db15e9591d0f9b520 (diff)
downloadmariadb-git-10.0-FusionIO.tar.gz
Merge tag 'mariadb-10.0.20' into 10.0-FusionIO10.0-FusionIO
Conflicts: storage/innobase/os/os0file.cc storage/xtradb/os/os0file.cc storage/xtradb/srv/srv0start.cc
Diffstat (limited to 'storage/mroonga/tools/travis/script.sh')
-rwxr-xr-xstorage/mroonga/tools/travis/script.sh114
1 files changed, 57 insertions, 57 deletions
diff --git a/storage/mroonga/tools/travis/script.sh b/storage/mroonga/tools/travis/script.sh
index 632a4db7a7e..6ea5c86068b 100755
--- a/storage/mroonga/tools/travis/script.sh
+++ b/storage/mroonga/tools/travis/script.sh
@@ -1,6 +1,6 @@
#!/bin/bash
#
-# Copyright(C) 2012-2014 Kouhei Sutou <kou@clear-code.com>
+# Copyright(C) 2012-2015 Kouhei Sutou <kou@clear-code.com>
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
@@ -24,95 +24,95 @@ top_dir="${base_dir}/../.."
bundled_mroonga_dir="${top_dir}/storage/mroonga"
if [ -f "${bundled_mroonga_dir}/config.sh" ]; then
- mroonga_dir="${bundled_mroonga_dir}"
- . "${bundled_mroonga_dir}/config.sh"
+ mroonga_dir="${bundled_mroonga_dir}"
+ . "${bundled_mroonga_dir}/config.sh"
else
- mroonga_dir="${top_dir}"
- . "${top_dir}/config.sh"
+ mroonga_dir="${top_dir}"
+ . "${top_dir}/config.sh"
fi
n_processors="$(grep '^processor' /proc/cpuinfo | wc -l)"
max_n_processors=8
if (( $n_processors > $max_n_processors )); then
- n_processors=$max_n_processors
+ n_processors=$max_n_processors
fi
build()
{
- if [ "${MROONGA_BUNDLED}" = "yes" ]; then
- make > /dev/null
- else
- make -j${n_processors} > /dev/null
- fi
+ if [ "${MROONGA_BUNDLED}" = "yes" ]; then
+ make -j${n_processors} > /dev/null
+ else
+ make -j${n_processors} > /dev/null
+ fi
}
run_unit_test()
{
- if [ "${MROONGA_BUNDLED}" != "yes" ]; then
- NO_MAKE=yes ${mroonga_dir}/test/run-unit-test.sh
- fi
+ if [ "${MROONGA_BUNDLED}" != "yes" ]; then
+ NO_MAKE=yes ${mroonga_dir}/test/run-unit-test.sh
+ fi
}
prepare_mysql_test_dir()
{
- mysql_test_dir=/usr/mysql-test
- if [ -d /usr/lib/mysql-testsuite/ ]; then
- sudo cp -a /usr/lib/mysql-testsuite/ ${mysql_test_dir}/
- elif [ -d /usr/share/mysql/mysql-test/ ]; then
- sudo cp -a /usr/share/mysql/mysql-test/ ${mysql_test_dir}/
- elif [ -d /opt/mysql/ ]; then
- mysql_test_dir=$(echo /opt/mysql/server-*/mysql-test)
- else
- sudo cp -a ${MYSQL_SOURCE_DIR}/mysql-test/ ${mysql_test_dir}/
- fi
- sudo chown -R $(id -u):$(id -g) ${mysql_test_dir}/
+ mysql_test_dir=/usr/mysql-test
+ if [ -d /usr/lib/mysql-testsuite/ ]; then
+ sudo cp -a /usr/lib/mysql-testsuite/ ${mysql_test_dir}/
+ elif [ -d /usr/share/mysql/mysql-test/ ]; then
+ sudo cp -a /usr/share/mysql/mysql-test/ ${mysql_test_dir}/
+ elif [ -d /opt/mysql/ ]; then
+ mysql_test_dir=$(echo /opt/mysql/server-*/mysql-test)
+ else
+ sudo cp -a ${MYSQL_SOURCE_DIR}/mysql-test/ ${mysql_test_dir}/
+ fi
+ sudo chown -R $(id -u):$(id -g) ${mysql_test_dir}/
- cp -a ${mroonga_dir}/mysql-test/mroonga/ ${mysql_test_dir}/suite/
+ cp -a ${mroonga_dir}/mysql-test/mroonga/ ${mysql_test_dir}/suite/
}
collect_test_suite_names()
{
- cd ${mysql_test_dir}/suite/
- test_suite_names=""
- for test_suite_name in $(find mroonga -type d '!' -name '[tr]'); do
- if [ -n "${test_suite_names}" ]; then
- test_suite_names="${test_suite_names},"
- fi
- test_suite_names="${test_suite_names}${test_suite_name}"
- done
- cd -
+ cd ${mysql_test_dir}/suite/
+ test_suite_names=""
+ for test_suite_name in $(find mroonga -type d '!' -name '[tr]'); do
+ if [ -n "${test_suite_names}" ]; then
+ test_suite_names="${test_suite_names},"
+ fi
+ test_suite_names="${test_suite_names}${test_suite_name}"
+ done
+ cd -
}
prepare_sql_test()
{
- sudo make install > /dev/null
- prepare_mysql_test_dir
- collect_test_suite_names
+ sudo make install > /dev/null
+ prepare_mysql_test_dir
+ collect_test_suite_names
}
run_sql_test()
{
- test_args=()
- if [ "${MROONGA_TEST_EMBEDDED}" = "yes" ]; then
- test_args=("${test_args[@]}" "--embedded-server")
- fi
+ test_args=()
+ if [ "${MROONGA_TEST_EMBEDDED}" = "yes" ]; then
+ test_args=("${test_args[@]}" "--embedded-server")
+ fi
- if [ "${MROONGA_BUNDLED}" = "yes" ]; then
- ${mroonga_dir}/test/run-sql-test.sh \
- "${test_args[@]}" \
- --parallel="${n_processors}"
- else
- prepare_sql_test
+ if [ "${MROONGA_BUNDLED}" = "yes" ]; then
+ ${mroonga_dir}/test/run-sql-test.sh \
+ "${test_args[@]}" \
+ --parallel="${n_processors}"
+ else
+ prepare_sql_test
- cd ${mysql_test_dir}/
- ./mysql-test-run.pl \
- "${test_args[@]}" \
- --no-check-testcases \
- --parallel="${n_processors}" \
- --retry=1 \
- --suite="${test_suite_names}" \
- --force
- fi
+ cd ${mysql_test_dir}/
+ ./mysql-test-run.pl \
+ "${test_args[@]}" \
+ --no-check-testcases \
+ --parallel="${n_processors}" \
+ --retry=1 \
+ --suite="${test_suite_names}" \
+ --force
+ fi
}
build