qutebrowser/tests
Ryan Roden-Corrent 888a1b8c57 Append multiple history backups on import.
Previously, a successful import of the text history into sqlite would
move 'history' to 'history.bak'. If history.bak already existed, this
would overwrite it on unix and fail on windows.

With this patch, the most recently imported history is appended to
history.bak to avoid data loss.

Resolves #3005.

A few other options I considered:

1. os.replace:
    - fast, simple, no error on Windows
    - potential data loss
2. numbered backups (.bak.1, .bak.2, ...):
    - fast, no data loss, but more complex
3. append each line to the backup as it is read:
    - more efficient than current patch (no need to read history twice)
    - potentially duplicate data if backup fails
2017-09-23 13:06:11 -04:00
..
end2end Stabilize test_quitting_process_expected 2017-09-21 13:42:24 +02:00
helpers Use .assert_not_called() for mocks 2017-09-22 19:58:38 +02:00
manual Update some more references to old config options 2017-07-04 16:46:02 +02:00
unit Append multiple history backups on import. 2017-09-23 13:06:11 -04:00
conftest.py Fix windows condition 2017-09-20 18:28:18 +02:00
test_conftest.py Finally update copyrights... 2017-05-09 21:37:03 +02:00