diff options
author | Jon Turney <jon.turney@dronecode.org.uk> | 2018-01-22 20:18:06 +0300 |
---|---|---|
committer | Jon Turney <jon.turney@dronecode.org.uk> | 2018-01-22 20:18:06 +0300 |
commit | 2c01547b2f7e986903a70dbd05426d137a3d4a43 (patch) | |
tree | 971139ccd9e9ace529726c84ffafbbfb46e2ffb1 | |
parent | acc487641ad58c62691844afa2cdc7677093086d (diff) |
Fix running pep8 on test/
-rwxr-xr-x | pep8 | 2 | ||||
-rw-r--r-- | test/__init__.py | 1 | ||||
-rwxr-xr-x | test/test_calm.py | 7 |
3 files changed, 5 insertions, 5 deletions
@@ -1,2 +1,2 @@ #!/bin/sh -grep -s -l '^#!/usr/bin/env python' calm/* tests/* | xargs python3 -m pycodestyle --count --show-source --max-line-length=240 --ignore=E129,E741 +grep -s -l '^#!/usr/bin/env python' calm/* test/* | xargs python3 -m pycodestyle --count --show-source --max-line-length=240 --ignore=E129,E741 diff --git a/test/__init__.py b/test/__init__.py index 2e574c0..9ce127e 100644 --- a/test/__init__.py +++ b/test/__init__.py @@ -1,2 +1 @@ from . import test_calm - diff --git a/test/test_calm.py b/test/test_calm.py index 7cacd01..35f0e24 100755 --- a/test/test_calm.py +++ b/test/test_calm.py @@ -105,6 +105,7 @@ def patched_pprint_ordered_dict(self, object, stream, indent, allowance, context context, level) write('}') + @contextlib.contextmanager def pprint_patch(): if isinstance(getattr(pprint.PrettyPrinter, '_dispatch', None), dict): @@ -117,6 +118,7 @@ def pprint_patch(): else: yield + # # # @@ -193,7 +195,7 @@ class CalmTest(unittest.TestCase): ["2.6.0+bzr6602-1", "2.6b2-1", 1], ["0.6.7+20150214+git3a710f9-1", "0.6.7-1", 1], ["15.8b-1", "15.8.0.1-2", -1], - ["1.2rc1-1","1.2.0-2", -1], + ["1.2rc1-1", "1.2.0-2", -1], # examples from https://fedoraproject.org/wiki/Archive:Tools/RPM/VersionComparison ["1.0010", "1.9", 1], ["1.05", "1.5", 0], @@ -441,8 +443,7 @@ class CalmTest(unittest.TestCase): (os.path.join(relarea_x86, 'keychain', 'keychain-2.6.8-1.tar.bz2'), '2016-11-02'), (os.path.join(relarea_x86, 'keychain', 'keychain-2.6.8-1-src.tar.bz2'), '2016-11-02'), (os.path.join(relarea_noarch, 'perl-Net-SMTP-SSL', 'perl-Net-SMTP-SSL-1.03-1.tar.xz'), '2016-11-01'), - (os.path.join(relarea_noarch, 'perl-Net-SMTP-SSL', 'perl-Net-SMTP-SSL-1.03-1-src.tar.xz'), '2016-11-01'), - ] + (os.path.join(relarea_noarch, 'perl-Net-SMTP-SSL', 'perl-Net-SMTP-SSL-1.03-1-src.tar.xz'), '2016-11-01')] for (f, t) in touches: os.system('touch %s -d %s' % (f, t)) |