diff --git a/tests/test_config_consistency.py b/tests/test_config_consistency.py index c17f7ea424..771c30d88b 100644 --- a/tests/test_config_consistency.py +++ b/tests/test_config_consistency.py @@ -110,9 +110,9 @@ def setup_query_string_obfuscation_configured_client(self): @missing_feature(context.library == "nodejs", reason="Node only obfuscates queries on the server side") @missing_feature(context.library == "golang", reason="Go only obfuscates queries on the server side") def test_query_string_obfuscation_configured_client(self): - interfaces.library.add_span_tag_validation( - self.r, tags={"http.url": r"^.*/\?$"}, value_as_regular_expression=True - ) + spans = [s for _, _, s in interfaces.library.get_spans(request=self.r, full_trace=True)] + client_span = _get_span_by_tags(spans, tags={"span.kind": "client", "http.url": "http://weblog:7777/?"}) + assert client_span, "\n".join([str(s) for s in spans]) def setup_query_string_obfuscation_configured_server(self): self.r = weblog.get("/?ssn=123-45-6789") @@ -131,9 +131,9 @@ def setup_query_string_obfuscation_configured_client(self): @missing_feature(context.library == "nodejs", reason="Node only obfuscates queries on the server side") @missing_feature(context.library == "golang", reason="Go only obfuscates queries on the server side") def test_query_string_obfuscation_configured_client(self): - interfaces.library.add_span_tag_validation( - self.r, tags={"http.url": r"^.*/\?$"}, value_as_regular_expression=True - ) + spans = [s for _, _, s in interfaces.library.get_spans(request=self.r, full_trace=True)] + client_span = _get_span_by_tags(spans, tags={"span.kind": "client", "http.url": "http://weblog:7777/?"}) + assert client_span, "\n".join([str(s) for s in spans]) def setup_query_string_obfuscation_configured_server(self): self.r = weblog.get("/?token=value")