summaryrefslogtreecommitdiff
path: root/test/bbackupd/testbbackupd.cpp
diff options
context:
space:
mode:
authorChris Wilson <chris+github@qwirx.com>2011-01-08 21:33:19 +0000
committerChris Wilson <chris+github@qwirx.com>2011-01-08 21:33:19 +0000
commit74313ca88404608767b6202313cb9bee51d5975e (patch)
tree4eb130d2b0a06a714229c91568fa2bb4f39d306f /test/bbackupd/testbbackupd.cpp
parent24d88d1bcbe740c230c6ddace0ef982b579e6af8 (diff)
Log the path, name and size of files being restored at TRACE level for
users wanting more detailed restore output. Disable printing dots when logging at TRACE level is enabled. Warn rather than failing to restore when the file attributes could not be restored. (merges [2745], [2827]).
Diffstat (limited to 'test/bbackupd/testbbackupd.cpp')
-rw-r--r--test/bbackupd/testbbackupd.cpp19
1 files changed, 11 insertions, 8 deletions
diff --git a/test/bbackupd/testbbackupd.cpp b/test/bbackupd/testbbackupd.cpp
index 2452c8c0..b82e83e3 100644
--- a/test/bbackupd/testbbackupd.cpp
+++ b/test/bbackupd/testbbackupd.cpp
@@ -521,7 +521,10 @@ void do_interrupted_restore(const TLSContext &context, int64_t restoredirid)
std::auto_ptr<BackupProtocolClientLoginConfirmed> loginConf(protocol.QueryLogin(0x01234567, BackupProtocolClientLogin::Flags_ReadOnly));
// Test the restoration
- TEST_THAT(BackupClientRestore(protocol, restoredirid, "testfiles/restore-interrupt", true /* print progress dots */) == Restore_Complete);
+ TEST_THAT(BackupClientRestore(protocol, restoredirid,
+ "Test1", "testfiles/restore-interrupt",
+ true /* print progress dots */)
+ == Restore_Complete);
// Log out
protocol.QueryFinished();
@@ -3431,7 +3434,7 @@ int test_bbackupd()
// Test the restoration
TEST_THAT(BackupClientRestore(*client, restoredirid,
- "testfiles/restore-Test1",
+ "Test1", "testfiles/restore-Test1",
true /* print progress dots */)
== Restore_Complete);
@@ -3440,7 +3443,7 @@ int test_bbackupd()
// Make sure you can't restore a restored directory
TEST_THAT(BackupClientRestore(*client, restoredirid,
- "testfiles/restore-Test1",
+ "Test1", "testfiles/restore-Test1",
true /* print progress dots */)
== Restore_TargetExists);
@@ -3451,7 +3454,7 @@ int test_bbackupd()
// Just check it doesn't bomb out -- will check this
// properly later (when bbackupd is stopped)
TEST_THAT(BackupClientRestore(*client, deldirid,
- "testfiles/restore-Test1-x1",
+ "Test1", "testfiles/restore-Test1-x1",
true /* print progress dots */,
true /* deleted files */)
== Restore_Complete);
@@ -3464,7 +3467,7 @@ int test_bbackupd()
{
Logging::Guard guard(Log::FATAL);
TEST_THAT(BackupClientRestore(*client,
- restoredirid,
+ restoredirid, "Test1",
"testfiles/no-such-path/subdir",
true /* print progress dots */)
== Restore_TargetPathNotFound);
@@ -3812,13 +3815,13 @@ int test_bbackupd()
// Check that the restore fn returns resume possible,
// rather than doing anything
TEST_THAT(BackupClientRestore(*client, restoredirid,
- "testfiles/restore-interrupt",
+ "Test1", "testfiles/restore-interrupt",
true /* print progress dots */)
== Restore_ResumePossible);
// Then resume it
TEST_THAT(BackupClientRestore(*client, restoredirid,
- "testfiles/restore-interrupt",
+ "Test1", "testfiles/restore-interrupt",
true /* print progress dots */,
false /* deleted files */,
false /* undelete server */,
@@ -3853,7 +3856,7 @@ int test_bbackupd()
// Do restore and undelete
TEST_THAT(BackupClientRestore(*client, deldirid,
- "testfiles/restore-Test1-x1-2",
+ "Test1", "testfiles/restore-Test1-x1-2",
true /* print progress dots */,
true /* deleted files */,
true /* undelete on server */)