Skip to content

Commit 0fd1e72

Browse files
committed
fix tests
1 parent e993d69 commit 0fd1e72

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

tests/integration_tests/test_telemetry.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,12 @@ def test_hub_traces_go_to_hub_telem_sink(self, mocker):
8181
"guardrails.utils.hub_telemetry_utils.OTLPSpanExporter",
8282
return_value=hub_exporter,
8383
)
84+
hub_processor = SimpleSpanProcessor(hub_exporter)
85+
86+
mocker.patch(
87+
"guardrails.utils.hub_telemetry_utils.BatchSpanProcessor",
88+
return_value=hub_processor,
89+
)
8490

8591
from guardrails import Guard
8692
from tests.integration_tests.test_assets.validators import LowerCase
@@ -126,6 +132,13 @@ def test_no_cross_contamination(self, mocker):
126132
)
127133
mock_hub_otlp_span_exporter.return_value = hub_exporter
128134

135+
hub_processor = SimpleSpanProcessor(hub_exporter)
136+
137+
mocker.patch(
138+
"guardrails.utils.hub_telemetry_utils.BatchSpanProcessor",
139+
return_value=hub_processor,
140+
)
141+
129142
from guardrails.telemetry import default_otel_collector_tracer
130143
from guardrails import Guard
131144
from tests.integration_tests.test_assets.validators import LowerCase

0 commit comments

Comments
 (0)