mirror of
https://github.com/borgbackup/borg.git
synced 2026-03-25 03:45:09 -04:00
test_attic013_acl_bug: use def instead of lambda
This commit is contained in:
parent
c2eb2539b9
commit
dfd748689c
1 changed files with 13 additions and 12 deletions
|
|
@ -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:
|
||||
|
|
|
|||
Loading…
Reference in a new issue