summaryrefslogtreecommitdiffstats
path: root/src/tests
diff options
context:
space:
mode:
authorLukas Slebodnik <lslebodn@redhat.com>2014-11-05 22:18:05 +0100
committerJakub Hrozek <jhrozek@redhat.com>2014-11-07 15:19:42 +0100
commit06e85cb08343ec902f0978ab0b6b373f1f1817f3 (patch)
treecdb903cb05760e4edc5ecf732db9f3fe7bdaddb8 /src/tests
parente08eb3e3b0586b331a688a4eded2d7f13611016c (diff)
downloadsssd-06e85cb08343ec902f0978ab0b6b373f1f1817f3.tar.gz
sssd-06e85cb08343ec902f0978ab0b6b373f1f1817f3.tar.xz
sssd-06e85cb08343ec902f0978ab0b6b373f1f1817f3.zip
test_sysdb_views: Use unique directory for cache
Two tests stored cache in the same directory, It can cause failures with parallel execution of tests. sh$ git grep tests_sysdb src/tests/cmocka/test_sysdb_views.c:#define TESTS_PATH "tests_sysdb" src/tests/sysdb-tests.c:#define TESTS_PATH "tests_sysdb" This patch also clean up potential leftovers after previous failed test_sysdb_views before execution of test suite. Reviewed-by: Pavel Březina <pbrezina@redhat.com>
Diffstat (limited to 'src/tests')
-rw-r--r--src/tests/cmocka/test_sysdb_views.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/tests/cmocka/test_sysdb_views.c b/src/tests/cmocka/test_sysdb_views.c
index 38525d6de..9fb2d7201 100644
--- a/src/tests/cmocka/test_sysdb_views.c
+++ b/src/tests/cmocka/test_sysdb_views.c
@@ -30,7 +30,7 @@
#include "tests/cmocka/common_mock.h"
-#define TESTS_PATH "tests_sysdb"
+#define TESTS_PATH "tests_sysdb_views"
#define TEST_CONF_FILE "tests_conf.ldb"
struct sysdb_test_ctx {
@@ -226,6 +226,8 @@ int main(int argc, const char *argv[])
DEBUG_CLI_INIT(debug_level);
tests_set_cwd();
+ test_dom_suite_cleanup(TESTS_PATH, TEST_CONF_FILE, LOCAL_SYSDB_FILE);
+ test_dom_suite_setup(TESTS_PATH);
rv = run_tests(tests);
if (rv == 0 && no_cleanup == 0) {