Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions manifests/java.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1041,6 +1041,7 @@ tests/:
akka-http: v1.22.0
spring-boot-3-native: missing_feature (GraalVM. Tracing support only)
test_asm_standalone.py:
Test_AppSecStandalone_NotEnabled: missing_feature
Test_AppSecStandalone_UpstreamPropagation:
'*': v1.36.0
spring-boot-3-native: missing_feature (GraalVM. Tracing support only)
Expand Down
19 changes: 19 additions & 0 deletions tests/test_the_test/test_scenario_names.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import re
from utils import scenarios
from utils._context._scenarios import get_all_scenarios


@scenarios.test_the_test
def test_scenario_names():
for scenario in get_all_scenarios():
name = scenario.name
assert re.fullmatch(
r"^[A-Z][A-Z\d_]+$", name
), f"'{name}' is not a valid name for a scenario, it should be only capital letters"

expected_property = name.lower()

assert hasattr(scenarios, expected_property), f"Scenarios object sould have the {expected_property} property"
assert (
getattr(scenarios, expected_property) is scenario
), f"scenarios.{expected_property} should be the {scenario} object"
4 changes: 2 additions & 2 deletions utils/_context/_scenarios/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class _Scenarios:
profiling = ProfilingScenario("PROFILING")

appsec_no_stats = EndToEndScenario(
"End to end tests with default value of DD_TRACE_COMPUTE_STATS",
name="APPSEC_NO_STATS",
doc=(
"End to end testing with default values. Default scenario has DD_TRACE_COMPUTE_STATS=true."
"This scenario let that env to use its default"
Expand Down Expand Up @@ -662,7 +662,7 @@ class _Scenarios:
scenario_groups=[ScenarioGroup.DEBUGGER],
)

fuzzer = DockerScenario("_FUZZER", doc="Fake scenario for fuzzing (launch without pytest)", github_workflow=None)
fuzzer = DockerScenario("FUZZER", doc="Fake scenario for fuzzing (launch without pytest)", github_workflow=None)

# Single Step Instrumentation scenarios (HOST and CONTAINER)

Expand Down
Loading