summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKali Kaneko <kali@leap.se>2015-08-04 12:18:50 -0400
committerKali Kaneko <kali@leap.se>2015-08-04 12:18:50 -0400
commit5a97000032cf9cdb8dee5310126f6de11b09d942 (patch)
treead4b6f576bcf488188cab873a9bc316c903daeba /src
parent570bf35249b1271a9453d5970059e080f2947d17 (diff)
[style] pep8 fixes + pep8 script
Diffstat (limited to 'src')
-rw-r--r--src/leap/mail/imap/server.py9
-rw-r--r--src/leap/mail/imap/tests/utils.py3
-rw-r--r--src/leap/mail/tests/__init__.py3
3 files changed, 10 insertions, 5 deletions
diff --git a/src/leap/mail/imap/server.py b/src/leap/mail/imap/server.py
index 050521a..39f483f 100644
--- a/src/leap/mail/imap/server.py
+++ b/src/leap/mail/imap/server.py
@@ -158,11 +158,14 @@ class LEAPIMAPServer(imap4.IMAP4Server):
else:
mf = imap4.IMessageFile(msg, None)
if mf is not None:
- return imap4.FileProducer(mf.open()).beginProducing(self.transport)
- return imap4.MessageProducer(msg, None, self._scheduler).beginProducing(self.transport)
+ return imap4.FileProducer(
+ mf.open()).beginProducing(self.transport)
+ return imap4.MessageProducer(
+ msg, None, self._scheduler).beginProducing(self.transport)
else:
- _w('BODY ' + imap4.collapseNestedLists([imap4.getBodyStructure(msg)]))
+ _w('BODY ' +
+ imap4.collapseNestedLists([imap4.getBodyStructure(msg)]))
##################################################################
#
diff --git a/src/leap/mail/imap/tests/utils.py b/src/leap/mail/imap/tests/utils.py
index 83c3f29..a34538b 100644
--- a/src/leap/mail/imap/tests/utils.py
+++ b/src/leap/mail/imap/tests/utils.py
@@ -99,7 +99,8 @@ class IMAP4HelperMixin(SoledadTestMixin):
# Soledad sync makes trial block forever. The sync it's mocked to
# fix this problem. _mock_soledad_get_from_index can be used from
# the tests to provide documents.
- # TODO see here, possibly related? -- http://www.pythoneye.com/83_20424875/
+ # TODO see here, possibly related?
+ # -- http://www.pythoneye.com/83_20424875/
self._soledad.sync = Mock()
d = defer.Deferred()
diff --git a/src/leap/mail/tests/__init__.py b/src/leap/mail/tests/__init__.py
index b35107d..de0088f 100644
--- a/src/leap/mail/tests/__init__.py
+++ b/src/leap/mail/tests/__init__.py
@@ -34,7 +34,8 @@ from leap.common.testing.basetest import BaseLeapTest
def _find_gpg():
gpg_path = distutils.spawn.find_executable('gpg')
- return os.path.realpath(gpg_path) if gpg_path is not None else "/usr/bin/gpg"
+ return (os.path.realpath(gpg_path)
+ if gpg_path is not None else "/usr/bin/gpg")
class TestCaseWithKeyManager(unittest.TestCase, BaseLeapTest):