]> git.ipfire.org Git - pbs.git/commitdiff
tests: package: Activate part that checks if a package has been removed
authorMichael Tremer <michael.tremer@ipfire.org>
Tue, 18 Oct 2022 13:21:49 +0000 (13:21 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Tue, 18 Oct 2022 13:21:49 +0000 (13:21 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
tests/package.py

index fcd46102388a012d4bbed93c1e2af30ade9c7e89..9024ada7bbed17728ea586de92e5d693626cd1a5 100755 (executable)
@@ -79,13 +79,15 @@ no notion of what's interesting, but it's real good at that notifying part.""")
                with self.db.transaction():
                        package = await self._create_package(path)
 
+               # Store the package path for later
+               path = package.path
+
                # Delete the package
                with self.db.transaction():
-                       package.delete()
+                       await package.delete()
 
                # Check if the payload has been removed
-               # XXX currently, packages are not deleted
-               #self.assertFalse(os.path.exists(package.path))
+               self.assertFalse(os.path.exists(path))
 
        async def test_files(self):
                """