Skip to content

Commit

Permalink
Check apm is disabled and dropping traces with no appsec events
Browse files Browse the repository at this point in the history
  • Loading branch information
iunanua committed Nov 20, 2024
1 parent 968c6b1 commit 42faab9
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion tests/appsec/test_asm_standalone.py
Original file line number Diff line number Diff line change
Expand Up @@ -698,9 +698,14 @@ def test_telemetry_sca_enabled_propagated(self):
assert cfg_appsec_enabled.get("value") == outcome_value

def setup_app_dependencies_loaded(self):
weblog.get("/load_dependency")
self.r = weblog.get("/load_dependency")

def test_app_dependencies_loaded(self):
# test standalone is enabled and dropping traces
for data, _trace, span in interfaces.library.get_spans(request=self.r):
assert span["metrics"]["_sampling_priority_v1"] == 0
assert span["metrics"]["_dd.apm.enabled"] == 0

seen_loaded_dependencies = TelemetryUtils.get_loaded_dependency(context.library.library)

for data in interfaces.library.get_telemetry_data():
Expand Down

0 comments on commit 42faab9

Please sign in to comment.