summaryrefslogtreecommitdiff
path: root/tests/utilities.py
diff options
context:
space:
mode:
authorThomas Nixon <tom@tomn.co.uk>2018-02-19 22:31:38 +0000
committerThomas Nixon <tom@tomn.co.uk>2018-02-19 23:15:29 +0000
commit01016563fccf31ddee6e5b8b4b13c065149dd814 (patch)
treeb40d9ec08e364ea7b21185b2379efa42e1b6a161 /tests/utilities.py
parent021735bdcba6763a5ed42cfce305e0ca33714db4 (diff)
Move screen stop/start logic into context manager.
As well as reducing duplication and adding screen size detection to :pipeto and :pyshell, this ensures that the screen is always restarted, resulting in cleaner error handling if an error occurs while the screen is stopped.
Diffstat (limited to 'tests/utilities.py')
-rw-r--r--tests/utilities.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/utilities.py b/tests/utilities.py
index ea4e700c..85f3d3eb 100644
--- a/tests/utilities.py
+++ b/tests/utilities.py
@@ -175,6 +175,7 @@ def make_key(revoked=False, expired=False, invalid=False, can_encrypt=True,
def make_ui(**kwargs):
ui = mock.Mock(**kwargs)
+ ui.paused.return_value = mock.MagicMock()
return ui