summaryrefslogtreecommitdiff
path: root/testing/tests/blobs
diff options
context:
space:
mode:
Diffstat (limited to 'testing/tests/blobs')
-rw-r--r--testing/tests/blobs/test_fs_backend.py15
1 files changed, 10 insertions, 5 deletions
diff --git a/testing/tests/blobs/test_fs_backend.py b/testing/tests/blobs/test_fs_backend.py
index a6d7272d..f742f702 100644
--- a/testing/tests/blobs/test_fs_backend.py
+++ b/testing/tests/blobs/test_fs_backend.py
@@ -153,14 +153,19 @@ class FilesystemBackendTestCase(unittest.TestCase):
def test_delete_blob(self, unlink_mock):
backend = _blobs.FilesystemBlobsBackend(self.tempdir)
backend.delete_blob('user', 'blob_id')
- unlink_mock.assert_called_once_with(backend._get_path('user',
- 'blob_id'))
+ unlink_mock.assert_any_call(backend._get_path('user',
+ 'blob_id'))
+ unlink_mock.assert_any_call(backend._get_path('user',
+ 'blob_id') + '.flags')
@pytest.mark.usefixtures("method_tmpdir")
@mock.patch('leap.soledad.server._blobs.os.unlink')
def test_delete_blob_custom_namespace(self, unlink_mock):
backend = _blobs.FilesystemBlobsBackend(self.tempdir)
backend.delete_blob('user', 'blob_id', namespace='trash')
- unlink_mock.assert_called_once_with(backend._get_path('user',
- 'blob_id',
- 'trash'))
+ unlink_mock.assert_any_call(backend._get_path('user',
+ 'blob_id',
+ 'trash'))
+ unlink_mock.assert_any_call(backend._get_path('user',
+ 'blob_id',
+ 'trash') + '.flags')