From 1136e37cf0d96f0a9f2a08f0ea24b390dc9914b1 Mon Sep 17 00:00:00 2001 From: Khushboo Vashi Date: Wed, 7 Mar 2018 16:48:32 +0000 Subject: [PATCH] Make the poll query test a little more robust. --- web/pgadmin/tools/sqleditor/tests/test_poll_query_tool.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/web/pgadmin/tools/sqleditor/tests/test_poll_query_tool.py b/web/pgadmin/tools/sqleditor/tests/test_poll_query_tool.py index 275ed9cd4..e0a8d388d 100644 --- a/web/pgadmin/tools/sqleditor/tests/test_poll_query_tool.py +++ b/web/pgadmin/tools/sqleditor/tests/test_poll_query_tool.py @@ -99,9 +99,11 @@ NOTICE: Hello, world! self.assertEquals(response.status_code, 200) response_data = json.loads(response.data.decode('utf-8')) - # Check the returned messages - self.assertEquals(self.expected_message[cnt], + if self.expected_message[cnt] is not None: + # Check the returned messages + self.assertIn(self.expected_message[cnt], response_data['data']['additional_messages']) + # Check the output self.assertEquals(self.expected_result[cnt], response_data['data']['result'][0][0])