mirror of
https://github.com/borgbackup/borg.git
synced 2024-12-26 01:37:20 +00:00
13ddfdf4a3
Using a decorator moves the duplicate code in the init methods into a single decorator method, while still retaining the same runtime overhead (zero for for the non-OSX path, one extra function call plus the call to unicodedata.normalize for OSX). The pattern classes are much visually cleaner, and duplicate code limited to two lines normalizing the pattern on OSX. Because the decoration happens at class init time (vs instance init time for the previous approach), the OSX and non-OSX test cases can no longer be called in the same run, so I also removed the OSX test case monkey patching and uncommented the platform skipif decorator. |
||
---|---|---|
.. | ||
testsuite | ||
__init__.py | ||
__main__.py | ||
_chunker.c | ||
_hashindex.c | ||
archive.py | ||
archiver.py | ||
cache.py | ||
chunker.pyx | ||
compress.pyx | ||
crypto.pyx | ||
fuse.py | ||
hashindex.pyx | ||
helpers.py | ||
key.py | ||
locking.py | ||
lrucache.py | ||
platform.py | ||
platform_darwin.pyx | ||
platform_freebsd.pyx | ||
platform_linux.pyx | ||
remote.py | ||
repository.py | ||
xattr.py |