From 74313ca88404608767b6202313cb9bee51d5975e Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Sat, 8 Jan 2011 21:33:19 +0000 Subject: 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]). --- test/bbackupd/testbbackupd.cpp | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) (limited to 'test') 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 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 */) -- cgit v1.2.3