Skip to content

Commit e948c90

Browse files
Fixing test cases
1 parent 999f056 commit e948c90

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

tests/observability/core/test_agent365.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ def test_configure_uses_existing_tracer_provider(self, mock_get_provider, mock_i
207207
return_value=False,
208208
)
209209
@patch.dict("os.environ", {"OTEL_EXPORTER_OTLP_ENDPOINT": "http://localhost:4318"}, clear=True)
210-
def test_otlp_exporter_initialized_when_env_var_set(self, mock_otlp_exporter):
210+
def test_otlp_exporter_initialized_when_env_var_set(self, mock_is_enabled, mock_otlp_exporter):
211211
"""Test that OTLPSpanExporter is initialized when OTEL_EXPORTER_OTLP_ENDPOINT is set."""
212212

213213
result = configure(
@@ -224,7 +224,9 @@ def test_otlp_exporter_initialized_when_env_var_set(self, mock_otlp_exporter):
224224
return_value=False,
225225
)
226226
@patch.dict("os.environ", {}, clear=True)
227-
def test_otlp_exporter_not_initialized_when_env_var_not_set(self, mock_otlp_exporter):
227+
def test_otlp_exporter_not_initialized_when_env_var_not_set(
228+
self, mock_is_enabled, mock_otlp_exporter
229+
):
228230
"""Test that OTLPSpanExporter is NOT initialized when OTEL_EXPORTER_OTLP_ENDPOINT is not set."""
229231

230232
result = configure(

0 commit comments

Comments
 (0)