diff options
author | Pavel Reichl <preichl@redhat.com> | 2014-05-28 15:12:06 +0100 |
---|---|---|
committer | Jakub Hrozek <jhrozek@redhat.com> | 2014-05-28 17:34:58 +0200 |
commit | 8ddcc64e343d6023f358a72a9515a0fa112db83b (patch) | |
tree | 1951d3fff5f98e0c797be55afe2c303eb37ce368 /src | |
parent | fa0e2bc21e1cca4d2196a0682d2b440977923b25 (diff) | |
download | sssd-8ddcc64e343d6023f358a72a9515a0fa112db83b.tar.gz sssd-8ddcc64e343d6023f358a72a9515a0fa112db83b.tar.xz sssd-8ddcc64e343d6023f358a72a9515a0fa112db83b.zip |
TEST: simple_access & sysdb tests - cleanup
Before running tests do cleanup.
Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/tests/simple_access-tests.c | 1 | ||||
-rw-r--r-- | src/tests/sysdb-tests.c | 8 |
2 files changed, 2 insertions, 7 deletions
diff --git a/src/tests/simple_access-tests.c b/src/tests/simple_access-tests.c index 0fa5d049f..999277340 100644 --- a/src/tests/simple_access-tests.c +++ b/src/tests/simple_access-tests.c @@ -661,6 +661,7 @@ int main(int argc, const char *argv[]) DEBUG_INIT(debug_level); tests_set_cwd(); + test_dom_suite_cleanup(TESTS_PATH, TEST_CONF_FILE, LOCAL_SYSDB_FILE); Suite *s = access_simple_suite(); SRunner *sr = srunner_create(s); diff --git a/src/tests/sysdb-tests.c b/src/tests/sysdb-tests.c index e3ed879b6..711d8f493 100644 --- a/src/tests/sysdb-tests.c +++ b/src/tests/sysdb-tests.c @@ -5621,7 +5621,6 @@ Suite *create_sysdb_suite(void) int main(int argc, const char *argv[]) { int opt; - int ret; poptContext pc; int failure_count; int no_cleanup = 0; @@ -5660,12 +5659,7 @@ int main(int argc, const char *argv[]) { tests_set_cwd(); - ret = unlink(TESTS_PATH"/"LOCAL_SYSDB_FILE); - if (ret != EOK && errno != ENOENT) { - fprintf(stderr, "Could not delete the test ldb file (%d) (%s)\n", - errno, strerror(errno)); - return EXIT_FAILURE; - } + test_dom_suite_cleanup(TESTS_PATH, TEST_CONF_FILE, LOCAL_SYSDB_FILE); sysdb_suite = create_sysdb_suite(); sr = srunner_create(sysdb_suite); |