diff --git a/debian/control b/debian/control
index 4b54d8e512c17a166c1ac7a6ce9d62efaea5b165..9007faabcd9619cde912f5143ce4ac481eb0990e 100644
--- a/debian/control
+++ b/debian/control
@@ -36,6 +36,7 @@ Recommends: python-qrencode
           , python-gtk2
           , python-zbar
           , python-zbarpygtk
+          , python-mock
 Suggests: monkeysign-doc
 Description: OpenPGP key signing and exchange for humans
  monkeysign is a tool to overhaul the OpenPGP keysigning experience
diff --git a/debian/tests/control b/debian/tests/control
index 2a1e779a6d1cc8cf9be619ea1b9f8d825a0173d7..e6157aabcd585c2c6f5d6578a1b20a07ba47bc96 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -1,3 +1,3 @@
 Test-command: monkeysign --test
-Depends: @
+Depends: @, python-mock
 Restrictions: allow-stderr
diff --git a/monkeysign/tests/test_ui.py b/monkeysign/tests/test_ui.py
index a1e0b574e446b0d76f50afa3a0744ddc71c2a00b..dbd219a8b3887cc5cfe571f225f8dd5efc3760d9 100755
--- a/monkeysign/tests/test_ui.py
+++ b/monkeysign/tests/test_ui.py
@@ -33,7 +33,10 @@ import tempfile
 try:
     from unittest.mock import Mock
 except ImportError:
-    from mock import Mock
+    try:
+        from mock import Mock
+    except:
+        Mock = False
 
 def which2(cmd):
     """naive implementation of which for Python 2"""
@@ -114,6 +117,8 @@ class CliBaseTest(unittest.TestCase):
     def tearDown(self):
         sys.argv = self.argv
 
+
+@unittest.skipUnless(Mock, 'mock library missing')
 class CliTestCase(CliBaseTest):
     def setUp(self):
         CliBaseTest.setUp(self)