mirror of
https://github.com/borgbackup/borg.git
synced 2024-12-23 00:07:38 +00:00
Enable pylint check E0211 (method has no argument) in .coafile
Adapt Attic013Item in test_attic013_acl_bug so that as_dict takes `self` as first argument. This was the only case where E0211 was violated.
This commit is contained in:
parent
26bc80f210
commit
f7c843fd21
2 changed files with 3 additions and 3 deletions
2
.coafile
2
.coafile
|
@ -24,7 +24,7 @@ pylint_disable = C0103, C0111, C0112, C0301, C0302, C0325, C0330, C0411, C0412,
|
|||
W0511, W0603, W0611, W0612, W0613, W0614, W0621, W0622, W0702, W0703,
|
||||
W1201, W1202, W1401, W1503, W1505,
|
||||
R0101, R0201, R0204, R0902, R0903, R0904, R0911, R0912, R0913, R0914, R0915, R0916,
|
||||
E0102, E0202, E0211, E0401, E0611, E0702, E1101, E1102, E1120, E1133
|
||||
E0102, E0202, E0401, E0611, E0702, E1101, E1102, E1120, E1133
|
||||
pydocstyle_ignore = D100, D101, D102, D103, D104, D105, D200, D201, D202, D203, D204, D205, D209, D210,
|
||||
D212, D213, D300, D301, D400, D401, D402, D403, D404
|
||||
|
||||
|
|
|
@ -2975,7 +2975,7 @@ def test_attic013_acl_bug(self):
|
|||
# a b'acl'=None key-value pair.
|
||||
# This bug can still live on in Borg repositories (through borg upgrade).
|
||||
class Attic013Item:
|
||||
def as_dict():
|
||||
def as_dict(self):
|
||||
return {
|
||||
# These are required
|
||||
b'path': '1234',
|
||||
|
@ -2994,7 +2994,7 @@ def as_dict():
|
|||
manifest, key = Manifest.load(repository, Manifest.NO_OPERATION_CHECK)
|
||||
with Cache(repository, key, manifest) as cache:
|
||||
archive = Archive(repository, key, manifest, '0.13', cache=cache, create=True)
|
||||
archive.items_buffer.add(Attic013Item)
|
||||
archive.items_buffer.add(Attic013Item())
|
||||
archive.save()
|
||||
self.cmd('check', self.repository_location, exit_code=0)
|
||||
self.cmd('list', self.repository_location + '::0.13', exit_code=0)
|
||||
|
|
Loading…
Reference in a new issue