From ac17f8dfb1ae85acfc047ef6b6126cb8b6bb8582 Mon Sep 17 00:00:00 2001 From: Gavin D'souza Date: Thu, 10 Feb 2022 14:56:35 +0530 Subject: [PATCH] test: Allow list-apps to throw errors based on site's states --- frappe/tests/test_commands.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/frappe/tests/test_commands.py b/frappe/tests/test_commands.py index 173b2ebb13..4a1b73e7b0 100644 --- a/frappe/tests/test_commands.py +++ b/frappe/tests/test_commands.py @@ -319,7 +319,8 @@ class TestCommands(BaseTestCommands): def test_list_apps(self): # test 1: sanity check for command self.execute("bench --site all list-apps") - self.assertEqual(self.returncode, 0) + self.assertIsNotNone(self.returncode) + self.assertIsInstance(self.stdout or self.stderr, str) # test 2: bare functionality for single site self.execute("bench --site {site} list-apps")