summary refs log tree commit diff
path: root/tests/unittest.py
diff options
context:
space:
mode:
authorMark Haines <mark.haines@matrix.org>2016-02-19 15:34:38 +0000
committerMark Haines <mark.haines@matrix.org>2016-02-19 15:34:38 +0000
commit700487a7c72c769537fb04c56d2e9c6dd29d7f84 (patch)
treef13b8706f7cdc4faa6e44e207fd57d3cfe30f97f /tests/unittest.py
parentAdd Measures to presence (diff)
downloadsynapse-700487a7c72c769537fb04c56d2e9c6dd29d7f84.tar.xz
Fix flake8 warnings for tests
Diffstat (limited to 'tests/unittest.py')
-rw-r--r--tests/unittest.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/unittest.py b/tests/unittest.py
index 6f02eb4cac..5b22abfe74 100644
--- a/tests/unittest.py
+++ b/tests/unittest.py
@@ -37,9 +37,12 @@ def around(target):
     def _around(code):
         name = code.__name__
         orig = getattr(target, name)
+
         def new(*args, **kwargs):
             return code(orig, *args, **kwargs)
+
         setattr(target, name, new)
+
     return _around
 
 
@@ -53,9 +56,7 @@ class TestCase(unittest.TestCase):
 
         method = getattr(self, methodName)
 
-        level = getattr(method, "loglevel",
-                    getattr(self, "loglevel",
-                        NEVER))
+        level = getattr(method, "loglevel", getattr(self, "loglevel", NEVER))
 
         @around(self)
         def setUp(orig):