testing.functional.test_restart module

class testing.functional.test_restart.RestartTest(methodName='runTest')[source]

Bases: FunctionalTestCase

Test checkpoint/restart using duplicity binary

make_fake_second_volume(name)[source]

Takes a successful backup and pretend that we interrupted a backup after two-volumes. (This is because we want to be able to model restarting the second volume and duplicity deletes the last volume found because it may have not finished uploading.)

test_basic_checkpoint_restart()[source]

Test basic Checkpoint/Restart

test_changed_source_dangling_manifest_volume()[source]

If we restart but find remote volumes missing, we can easily end up with a manifest that lists “vol1, vol2, vol3, vol2”, leaving a dangling vol3. Make sure we can gracefully handle that. This will only happen if the source data changes to be small enough to not create a vol3 on restart.

test_changed_source_file_disappears()[source]

Make sure we correctly handle restarting a backup when a file disappears when we had been in the middle of backing it up. It’s possible that the first chunk of the next file will be skipped unless we’re careful.

test_first_volume_failure()[source]

Test restart when no volumes are available on the remote. Caused when duplicity fails before the first transfer.

test_last_file_missing_at_end()[source]

Test restart when the last file being backed up is missing on restart. Caused when the user deletes a file after a failure. This test puts the file at the end of the backup, with no files following.

test_last_file_missing_in_middle()[source]

Test restart when the last file being backed up is missing on restart. Caused when the user deletes a file after a failure. This test puts the file in the middle of the backup, with files following.

test_multi_volume_failure()[source]

Test restart when fewer volumes are available on the remote than the local manifest has on record. Caused when duplicity fails the last queued transfer(s).

test_multiple_checkpoint_restart()[source]

Test multiple Checkpoint/Restart

test_new_file()[source]

If we restart right after a volume, but there are new files that would have been backed up earlier in the volume, make sure we don’t wig out. (Expected result is to ignore new, ealier files, but pick up later ones.)

test_restart_encrypt_without_password()[source]

Test that we can successfully restart a encrypt-key-only backup without providing a password for it. (Normally, we’d need to decrypt the first volume, but there is special code to skip that with an encrypt key.)

test_restart_incremental()[source]

Test restarting an incremental backup

test_restart_sign_and_encrypt()[source]

Test restarting a backup using same key for sign and encrypt https://bugs.launchpad.net/duplicity/+bug/946988

test_restart_sign_and_hidden_encrypt()[source]

Test restarting a backup using same key for sign and encrypt (hidden key id) https://bugs.launchpad.net/duplicity/+bug/946988

test_split_after_large()[source]

If we restart right after a volume that ended with a large (multi-block) file, make sure we restart in the right place.

test_split_after_small()[source]

If we restart right after a volume that ended with a small (one-block) file, make sure we restart in the right place.

test_split_inside_large()[source]

If we restart right after a volume that ended inside of a large (multi-block) file, make sure we restart in the right place.

class testing.functional.test_restart.RestartTestConcurrent(methodName='runTest')[source]

Bases: RestartTest

setUp()[source]

Hook method for setting up the test fixture before exercising it.

class testing.functional.test_restart.RestartTestWithoutEncryption(methodName='runTest')[source]

Bases: RestartTest

setUp()[source]

Hook method for setting up the test fixture before exercising it.

test_ignore_double_snapshot()[source]

Test that we gracefully ignore double snapshot entries in a signature file. This winds its way through duplicity as a deleted base dir, which doesn’t make sense and should be ignored. An older version of duplicity accidentally created such files as a result of a restart. https://launchpad.net/bugs/929067

test_no_write_double_snapshot()[source]

Test that restarting a full backup does not write duplicate entries into the sigtar, causing problems reading it back in older versions. https://launchpad.net/bugs/929067