diff options
author | bescoto <bescoto@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109> | 2005-10-31 04:53:31 +0000 |
---|---|---|
committer | bescoto <bescoto@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109> | 2005-10-31 04:53:31 +0000 |
commit | a5c03feacbbd9361eb3e2abe367b75529c83459b (patch) | |
tree | bcb8f86bf8cfc61bd771b6e45d557bdda7604e80 /rdiff-backup/testing/commontest.py | |
parent | a2705f514b471e2b74c98a0cde588863e3ff22c6 (diff) | |
download | rdiff-backup-a5c03feacbbd9361eb3e2abe367b75529c83459b.tar.gz |
Added various compare options like --compare-full and --compare-hash
git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup/trunk@664 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109
Diffstat (limited to 'rdiff-backup/testing/commontest.py')
-rw-r--r-- | rdiff-backup/testing/commontest.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/rdiff-backup/testing/commontest.py b/rdiff-backup/testing/commontest.py index 3113b21..b205c0a 100644 --- a/rdiff-backup/testing/commontest.py +++ b/rdiff-backup/testing/commontest.py @@ -40,7 +40,8 @@ def MakeOutputDir(): return rp def rdiff_backup(source_local, dest_local, src_dir, dest_dir, - current_time = None, extra_options = ""): + current_time = None, extra_options = "", + check_return_val = 1): """Run rdiff-backup with the given options source_local and dest_local are boolean values. If either is @@ -70,7 +71,9 @@ def rdiff_backup(source_local, dest_local, src_dir, dest_dir, cmdargs.extend([src_dir, dest_dir]) cmdline = " ".join(cmdargs) print "Executing: ", cmdline - assert not os.system(cmdline) + ret_val = os.system(cmdline) + if check_return_val: assert not ret_val, ret_val + return ret_val def InternalBackup(source_local, dest_local, src_dir, dest_dir, current_time = None, eas = None, acls = None): |