summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruno Wagner Goncalves <bwagner@thoughtworks.com>2014-08-21 15:05:33 -0300
committerBruno Wagner Goncalves <bwagner@thoughtworks.com>2014-08-21 15:05:33 -0300
commit592b7cbc561af91fed8e7d02b869ebe2f910b585 (patch)
tree6e5ccd0bc4c2aae4efa53b924b9d09ed97e01719
parent43e5beb9b5bc886f89704c00f764da1feab4674c (diff)
Added fallback in case the gpg binary is not found on the PATH
-rw-r--r--mail/src/leap/mail/smtp/tests/__init__.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/mail/src/leap/mail/smtp/tests/__init__.py b/mail/src/leap/mail/smtp/tests/__init__.py
index 5dc74659..dc24293f 100644
--- a/mail/src/leap/mail/smtp/tests/__init__.py
+++ b/mail/src/leap/mail/smtp/tests/__init__.py
@@ -42,8 +42,8 @@ from leap.common.testing.basetest import BaseLeapTest
def _find_gpg():
gpg_path = distutils.spawn.find_executable('gpg')
- return os.path.realpath(gpg_path)
-
+ return os.path.realpath(gpg_path) if gpg_path is not None else "/usr/bin/gpg"
+
class TestCaseWithKeyManager(BaseLeapTest):