summaryrefslogtreecommitdiff
path: root/tests/commands/test_global.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/commands/test_global.py')
-rw-r--r--tests/commands/test_global.py10
1 files changed, 4 insertions, 6 deletions
diff --git a/tests/commands/test_global.py b/tests/commands/test_global.py
index 3d69bd04..92b48955 100644
--- a/tests/commands/test_global.py
+++ b/tests/commands/test_global.py
@@ -115,12 +115,10 @@ class TestComposeCommand(unittest.TestCase):
envelope.account.address = 1 # maybe this should be a real Address?
cmd = g_commands.ComposeCommand(envelope=envelope)
- with mock.patch('alot.commands.globals.settings.get_addressbooks',
- mock.Mock(side_effect=Stop)):
- try:
- await cmd.apply(mock.Mock())
- except Stop:
- pass
+ cmd._set_envelope()
+ with mock.patch('alot.commands.globals.settings.get_accounts',
+ mock.Mock(return_value=[account])):
+ await cmd._set_from()
class TestExternalCommand(unittest.TestCase):