Skip to content

Commit a40b960

Browse files
committed
test(libdatadog): Add test for phase 1
1 parent ca62de8 commit a40b960

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

tests/internal/test_native.py

+16-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,22 @@
11
from ddtrace.internal.native import get_configuration_from_disk
22

33

4-
def test_get_configuration_from_disk(tmp_path):
4+
def test_get_configuration_from_disk__host_selector(tmp_path):
5+
# First test -- config matches & should be returned
6+
config_1 = tmp_path / "config_1.yaml"
7+
config_1.write_text(
8+
"""
9+
apm_configuration_default:
10+
DD_RUNTIME_METRICS_ENABLED: true
11+
""",
12+
encoding="utf-8",
13+
)
14+
15+
config = get_configuration_from_disk(file_override=str(config_1))
16+
assert config == {"DD_RUNTIME_METRICS_ENABLED": "true"}
17+
18+
19+
def test_get_configuration_from_disk__service_selector(tmp_path):
520
# First test -- config matches & should be returned
621
config_1 = tmp_path / "config_1.yaml"
722
config_1.write_text(

0 commit comments

Comments
 (0)