diff --git a/go/apps/http_api_nostream/tests/test_vumi_app.py b/go/apps/http_api_nostream/tests/test_vumi_app.py index 963a7b886..0ca65a778 100644 --- a/go/apps/http_api_nostream/tests/test_vumi_app.py +++ b/go/apps/http_api_nostream/tests/test_vumi_app.py @@ -396,10 +396,10 @@ def test_post_inbound_message_no_url(self): yield self.conversation.save() msg = self.msg_helper.make_inbound('in 1', message_id='1') - with LogCatcher(message='URL not configured') as lc: + with LogCatcher(message='push_message_url not configured') as lc: yield self.dispatch_to_conv(msg, self.conversation) [url_not_configured_log] = lc.messages() - self.assertTrue('push_message_url' in url_not_configured_log) + self.assertTrue(self.conversation.key in url_not_configured_log) @inlineCallbacks def test_post_inbound_message_unsupported_scheme(self): @@ -457,10 +457,10 @@ def test_post_inbound_event_no_url(self): msg1 = yield self.msg_helper.make_stored_outbound( self.conversation, 'out 1', message_id='1') ack1 = self.msg_helper.make_ack(msg1) - with LogCatcher(message='URL not configured') as lc: + with LogCatcher(message='push_event_url not configured') as lc: yield self.dispatch_event_to_conv(ack1, self.conversation) [url_not_configured_log] = lc.messages() - self.assertTrue('push_event_url' in url_not_configured_log) + self.assertTrue(self.conversation.key in url_not_configured_log) @inlineCallbacks def test_post_inbound_event_timeout(self): diff --git a/go/apps/http_api_nostream/vumi_app.py b/go/apps/http_api_nostream/vumi_app.py index 183453061..75b1f9df7 100644 --- a/go/apps/http_api_nostream/vumi_app.py +++ b/go/apps/http_api_nostream/vumi_app.py @@ -74,7 +74,9 @@ def consume_user_message(self, message): push_message_url = self.get_api_config(conversation, 'push_message_url') if push_message_url is None: - log.warning("URL not configured: push_message_url") + log.warning( + "push_message_url not configured for conversation: %s" % ( + conversation.key)) return yield self.push(push_message_url, message) @@ -93,7 +95,9 @@ def consume_unknown_event(self, event): conversation = config.get_conversation() push_event_url = self.get_api_config(conversation, 'push_event_url') if push_event_url is None: - log.warning("URL not configured: push_event_url") + log.warning( + "push_event_url not configured for conversation: %s" % ( + conversation.key)) return yield self.push(push_event_url, event)