use append mode in symlink unit test
authorPhilipp Gesang <philipp.gesang@intra2net.com>
Thu, 27 Apr 2017 15:18:31 +0000 (17:18 +0200)
committerThomas Jarosch <thomas.jarosch@intra2net.com>
Mon, 2 Apr 2018 11:34:08 +0000 (13:34 +0200)
These tests currently fail despite using the original Gzipfile
compression path. The archives appear to overwrite instead the
passed archive instead of writing new objects.

testing/test_deltatar.py

index b776d5b..f6e8095 100644 (file)
@@ -1512,7 +1512,6 @@ class DeltaTarTest(BaseTest):
         Creates a full backup containing different varieties of symlinks. All
         of them must be filtered out.
         '''
-
         password, paramversion = self.ENCRYPTION or (None, None)
         deltatar = DeltaTar(mode=self.MODE, password=password,
                             crypto_paramversion=paramversion,
@@ -1537,7 +1536,7 @@ class DeltaTarTest(BaseTest):
             a.addfile(l)
             return name
 
-        with tarfile.open(tar_path,mode="w") as a:
+        with tarfile.open(tar_path,mode="a") as a:
             checkme = \
                 [ add_symlink(a, "symlinks/foo", "internal-file")
                 , add_symlink(a, "symlinks/bar", "/absolute/path")