From dfd748689c459d648f7861c1cf8bc2ea1044f941 Mon Sep 17 00:00:00 2001 From: Marian Beermann Date: Sun, 13 Nov 2016 17:30:42 +0100 Subject: [PATCH] test_attic013_acl_bug: use def instead of lambda --- src/borg/testsuite/archiver.py | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/src/borg/testsuite/archiver.py b/src/borg/testsuite/archiver.py index 490086503..d59d05f11 100644 --- a/src/borg/testsuite/archiver.py +++ b/src/borg/testsuite/archiver.py @@ -2166,18 +2166,19 @@ class ArchiverCheckTestCase(ArchiverTestCaseBase): # a b'acl'=None key-value pair. # This bug can still live on in Borg repositories (through borg upgrade). class Attic013Item: - as_dict = lambda: { - # These are required - b'path': '1234', - b'mtime': 0, - b'mode': 0, - b'user': b'0', - b'group': b'0', - b'uid': 0, - b'gid': 0, - # acl is the offending key. - b'acl': None, - } + def as_dict(): + return { + # These are required + b'path': '1234', + b'mtime': 0, + b'mode': 0, + b'user': b'0', + b'group': b'0', + b'uid': 0, + b'gid': 0, + # acl is the offending key. + b'acl': None, + } archive, repository = self.open_archive('archive1') with repository: