From d603402ce6dc67b518dfdf3a6bc6ce2cd162f0df Mon Sep 17 00:00:00 2001 From: Munir Abdinur Date: Mon, 23 Sep 2024 22:34:16 -0400 Subject: [PATCH] chore(requests): fix local test runs --- .gitlab/services.yml | 2 +- tests/contrib/requests/test_requests.py | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.gitlab/services.yml b/.gitlab/services.yml index daefb0986e..39c1703d04 100644 --- a/.gitlab/services.yml +++ b/.gitlab/services.yml @@ -45,7 +45,7 @@ KAFKA_CFG_CONTROLLER_LISTENER_NAMES: CONTROLLER httpbin_local: name: registry.ddbuild.io/images/mirror/mccutchen/go-httpbin:v2.14.1 - alias: httpbin-local + alias: httpbin_local variables: PORT: 8001 memcached: diff --git a/tests/contrib/requests/test_requests.py b/tests/contrib/requests/test_requests.py index 44b2f06708..5a6244a158 100644 --- a/tests/contrib/requests/test_requests.py +++ b/tests/contrib/requests/test_requests.py @@ -24,7 +24,7 @@ from tests.utils import override_global_tracer -HOST_AND_PORT = "httpbin-local:8001" +HOST_AND_PORT = "localhost:8001" SOCKET = HOST_AND_PORT.split(":")[0] URL_200 = "http://{}/status/200".format(HOST_AND_PORT) URL_500 = "http://{}/status/500".format(HOST_AND_PORT) @@ -243,9 +243,8 @@ def test_non_existant_url(self): assert s.get_tag("span.kind") == "client" assert s.get_tag("out.host") == "doesnotexist.google.com" assert s.error == 1 - assert "Name or service not known" in s.get_tag(ERROR_MSG) - assert "Name or service not known" in s.get_tag(ERROR_STACK) - assert "Traceback (most recent call last)" in s.get_tag(ERROR_STACK) + assert "nodename nor servname provided, or not known" in s.get_tag(ERROR_MSG) + assert s.get_tag(ERROR_STACK) assert "requests.exception" in s.get_tag(ERROR_TYPE) def test_500(self):