[Pkg-owncloud-commits] [owncloud-client] 99/333: Remove check_csync_treewalk_remote
Sandro Knauß
hefee-guest at moszumanska.debian.org
Thu Apr 17 23:16:39 UTC 2014
This is an automated email from the git hooks/post-receive script.
hefee-guest pushed a commit to branch master
in repository owncloud-client.
commit 7f07385fd7addc9dfc46eb774462de2614e8fcf6
Author: Olivier Goffart <ogoffart at woboq.com>
Date: Thu Mar 6 14:24:53 2014 +0100
Remove check_csync_treewalk_remote
Since we removed the vio abstraction, we cannot use the file system anymore
as a remote. and because we unfortunately can't use a real server,
just disable that test.
---
csync/tests/csync_tests/check_csync_treewalk.c | 61 --------------------------
1 file changed, 61 deletions(-)
diff --git a/csync/tests/csync_tests/check_csync_treewalk.c b/csync/tests/csync_tests/check_csync_treewalk.c
index 6036fbd..31d0ee4 100644
--- a/csync/tests/csync_tests/check_csync_treewalk.c
+++ b/csync/tests/csync_tests/check_csync_treewalk.c
@@ -64,42 +64,6 @@ static void teardown_local(void **state) {
system("rm -rf /tmp/check_csync");
}
-static void setup_remote(void **state) {
- CSYNC *csync = (CSYNC *)*state;
- int rc;
-
- rc = system("mkdir -p /tmp/check_csync1");
- assert_int_equal(rc, 0);
-
- rc = system("mkdir -p /tmp/check_csync2");
- assert_int_equal(rc, 0);
-
- rc = system("echo \"This is test data\" > /tmp/check_csync2/testfile1.txt");
- assert_int_equal(rc, 0);
-
- rc = system("echo \"This is also test data\" > /tmp/check_csync2/testfile2.txt");
- assert_int_equal(rc, 0);
-
- rc = csync_create(&csync, "/tmp/check_csync1", "/tmp/check_csync2");
- assert_int_equal(rc, 0);
-
- rc = csync_set_config_dir(csync, "/tmp/check_csync/");
- assert_int_equal(rc, 0);
-
- rc = csync_init(csync);
- assert_int_equal(rc, 0);
-
- *state = csync;
-}
-
-static void teardown_remote(void **state) {
- CSYNC *csync = (CSYNC *)*state;
-
- csync_destroy(csync);
- system("rm -rf /tmp/check_csync1");
- system("rm -rf /tmp/check_csync2");
-}
-
static int visitor(TREE_WALK_FILE* file, void *userdata)
{
int *file_count;
@@ -134,30 +98,6 @@ static void check_csync_treewalk_local(void **state)
assert_int_equal(file_count, 2);
}
-static void check_csync_treewalk_remote(void **state)
-{
- CSYNC *csync = (CSYNC *)*state;
- int file_count = 0;
- int rc;
-
- csync_set_userdata(csync, &file_count);
-
- assert_non_null(csync->remote.tree);
-
- rc = csync_walk_remote_tree(csync, &visitor, 0);
- assert_int_equal(rc, 0);
- assert_int_equal(file_count, 0);
-
- /* reconcile doesn't update the tree */
- rc = csync_update(csync);
- assert_int_equal(rc, 0);
-
- rc = csync_walk_remote_tree(csync, &visitor, 0);
- assert_int_equal(rc, 0);
-
- assert_int_equal(file_count, 2);
-}
-
static void check_csync_treewalk_local_with_filter(void **state)
{
CSYNC *csync = (CSYNC *)*state;
@@ -194,7 +134,6 @@ int torture_run_tests(void)
{
const UnitTest tests[] = {
unit_test_setup_teardown(check_csync_treewalk_local, setup_local, teardown_local ),
- unit_test_setup_teardown(check_csync_treewalk_remote, setup_remote, teardown_remote),
unit_test_setup_teardown(check_csync_treewalk_local_with_filter, setup_local, teardown_local)
};
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud-client.git
More information about the Pkg-owncloud-commits
mailing list