summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBarry Warsaw2016-04-29 18:59:23 -0400
committerGitLab2016-04-29 23:01:30 +0000
commit1b46e6b6262109d4befbb5a1c534ffde25d702fb (patch)
tree0de8e136e912089a5daf71e1bc415ea86e9cb371 /src
parent63375f10b530a5e573c9aff82cd351de5a1b4dc1 (diff)
downloadmailman-1b46e6b6262109d4befbb5a1c534ffde25d702fb.tar.gz
mailman-1b46e6b6262109d4befbb5a1c534ffde25d702fb.tar.zst
mailman-1b46e6b6262109d4befbb5a1c534ffde25d702fb.zip
Diffstat (limited to 'src')
-rw-r--r--src/mailman/commands/tests/test_shell.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mailman/commands/tests/test_shell.py b/src/mailman/commands/tests/test_shell.py
index 153591f5a..12e78c1ab 100644
--- a/src/mailman/commands/tests/test_shell.py
+++ b/src/mailman/commands/tests/test_shell.py
@@ -27,6 +27,12 @@ from mailman.testing.helpers import configuration
from mailman.testing.layers import ConfigLayer
from unittest.mock import patch
+try:
+ import readline # noqa
+ has_readline = True
+except ImportError:
+ has_readline = False
+
class FakeArgs:
interactive = None
@@ -64,6 +70,7 @@ class TestShell(unittest.TestCase):
positional, keywords = mock.call_args
self.assertEqual(keywords['banner'], 'my banner\n')
+ @unittest.skipUnless(has_readline, 'readline module is not available')
@configuration('shell', history_file='$var_dir/history.py')
def test_history_file(self):
args = FakeArgs()