summaryrefslogtreecommitdiff
path: root/common/src/leap/soledad
diff options
context:
space:
mode:
authorKali Kaneko <kali@leap.se>2015-08-20 23:44:25 -0400
committerKali Kaneko <kali@leap.se>2015-08-20 23:44:25 -0400
commit2d99ba164e3711af22434dde3be95460eff8b28b (patch)
tree90ab4e7e320bbf562a60eb1e8f910cfa6771d3dc /common/src/leap/soledad
parentc050a98302f07eac99cf2576750878b2417cff15 (diff)
[style] pep8 fixes
Diffstat (limited to 'common/src/leap/soledad')
-rw-r--r--common/src/leap/soledad/common/tests/test_couch.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/common/src/leap/soledad/common/tests/test_couch.py b/common/src/leap/soledad/common/tests/test_couch.py
index 021888c1..468ad8d8 100644
--- a/common/src/leap/soledad/common/tests/test_couch.py
+++ b/common/src/leap/soledad/common/tests/test_couch.py
@@ -547,9 +547,11 @@ class CouchDatabaseSyncTargetTests(
called)
def test__set_trace_hook_shallow(self):
- if (self.st._set_trace_hook_shallow == self.st._set_trace_hook
- or self.st._set_trace_hook_shallow.im_func ==
- SyncTarget._set_trace_hook_shallow.im_func):
+ st_trace_shallow = self.st._set_trace_hook_shallow
+ target_st_trace_shallow = SyncTarget._set_trace_hook_shallow
+ same_meth = st_trace_shallow == self.st._set_trace_hook
+ same_fun = st_trace_shallow.im_func == target_st_trace_shallow.im_func
+ if (same_meth or same_fun):
# shallow same as full
expected = ['before whats_changed',
'after whats_changed',
@@ -689,8 +691,8 @@ class CouchDatabaseSyncTests(
# NINJA TO YOUR HOUSE.
db_copy = self.copy_database_for_test(self, db)
name, orig_sync_role = self._use_tracking[db]
- self._use_tracking[db_copy] = (name + '(copy)', sync_role
- or orig_sync_role)
+ self._use_tracking[db_copy] = (
+ name + '(copy)', sync_role or orig_sync_role)
return db_copy
def sync(self, db_from, db_to, trace_hook=None,