Skip to content

Commit a4c51da

Browse files
committed
test: validate host.name for EC2
1 parent eb20dd4 commit a4c51da

File tree

3 files changed

+19
-2
lines changed

3 files changed

+19
-2
lines changed

distributions/nrdot-collector-host/test/spec-nightly.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,5 @@ nightly:
44
ec2:
55
enabled: true
66
testCaseSpecs:
7-
- host
7+
- host
8+
- resourcedetection

distributions/nrdot-collector/test/spec-nightly.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,5 @@ nightly:
44
ec2:
55
enabled: true
66
testCaseSpecs:
7-
- host
7+
- host
8+
- resourcedetection
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
whereClause:
2+
template: "WHERE testKey like '{{ .testKey }}'"
3+
vars:
4+
- testKey
5+
6+
testCases:
7+
resourcedetection/cloud.ec2_host_name:
8+
metric:
9+
# any metric processed by resourcedetection works
10+
name: system.cpu.utilization
11+
whereClause: WHERE host.name like 'ip-%'
12+
assertions:
13+
- aggregationFunction: max
14+
comparisonOperator: ">"
15+
threshold: 0

0 commit comments

Comments
 (0)