From 909c70dd83e5f09c6129f737cf6de99cf605b78c Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Thu, 20 Nov 2014 09:48:30 +0100 Subject: postgresql-odbc-tests: new testsuite * postgresql-odbc-tests/libdtf: New symlink. * postgresql-odbc-tests/run: Likewise. * postgresql-odbc-tests/tasks/upstream-testsuite/runtest.sh: New file. --- postgresql-odbc-tests/libdtf | 1 + postgresql-odbc-tests/run | 1 + .../tasks/upstream-testsuite/runtest.sh | 30 ++++++++++++++++++++++ 3 files changed, 32 insertions(+) create mode 120000 postgresql-odbc-tests/libdtf create mode 120000 postgresql-odbc-tests/run create mode 100644 postgresql-odbc-tests/tasks/upstream-testsuite/runtest.sh (limited to 'postgresql-odbc-tests') diff --git a/postgresql-odbc-tests/libdtf b/postgresql-odbc-tests/libdtf new file mode 120000 index 0000000..2aca4c4 --- /dev/null +++ b/postgresql-odbc-tests/libdtf @@ -0,0 +1 @@ +../tester/libdtf \ No newline at end of file diff --git a/postgresql-odbc-tests/run b/postgresql-odbc-tests/run new file mode 120000 index 0000000..adeed00 --- /dev/null +++ b/postgresql-odbc-tests/run @@ -0,0 +1 @@ +../tester/run \ No newline at end of file diff --git a/postgresql-odbc-tests/tasks/upstream-testsuite/runtest.sh b/postgresql-odbc-tests/tasks/upstream-testsuite/runtest.sh new file mode 100644 index 0000000..1b7da92 --- /dev/null +++ b/postgresql-odbc-tests/tasks/upstream-testsuite/runtest.sh @@ -0,0 +1,30 @@ +export DTF_TEST_ID="upstream-testsuite" +export DTF_TEST_DESCRIPTION="Run the upstream testsuite available with +distribution tarball." + +check_libdir() +{ + test -d "$1" || return 0 + cd "$1" || return 1 + su postgres -c "make installcheck" +} + +run() +{ + local libsubdir="postgresql-odbc/test/" + local dir= + local rc=$DTF_RESULT_SUCCESS + + for i in /usr/lib64 /usr/lib; do + dir="$i/$libsubdir" + check_libdir "$dir" || { + rc="$DTF_RESULT_FAILURE" + cat "$dir/regression.diffs" + break + } + done + + dtf_generate_results_tarball "$dir" + + return "$rc" +} -- cgit