Skip to content

Commit

Permalink
fix test case and change default image
Browse files Browse the repository at this point in the history
  • Loading branch information
rockb1017 committed Jul 1, 2021
1 parent 19ea6a8 commit e85c41e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 12 deletions.
5 changes: 3 additions & 2 deletions charts/sck-otel/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,11 @@ batch:
send_batch_max_size: 0

image:
repository: otel/opentelemetry-collector-contrib
repository: rock1017/otelcontribcol
# repository: otel/opentelemetry-collector-contrib
pullPolicy: IfNotPresent
# Overrides the image tag whose default is the chart appVersion.
tag: ""
tag: "0.30.0"
imagePullSecrets: []

# OpenTelemetry Collector executable
Expand Down
3 changes: 0 additions & 3 deletions ci_scripts/sck_otel_values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,6 @@ containers:
from: namespace
- key: splunk.com/exclude
from: namespace
- key: splunk.com/customField
tag_name: customField
from: namespace
listOfLabels:
- key: app
from: pod
Expand Down
14 changes: 7 additions & 7 deletions test/k8s_logging_tests/test_config_logging.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,11 @@ def test_label_collection(setup, label, index, expected):
assert len(events) >= expected


@pytest.mark.parametrize("container_name,expected", [
("pod-w-index-w-ns-index", 1),
("pod-wo-index-w-ns-index", 1),
("pod-w-index-wo-ns-index", 1),
("pod-wo-index-wo-ns-index", 1),
@pytest.mark.parametrize("index,container_name,expected", [
("pod-anno", "pod-w-index-w-ns-index", 1),
("ns-anno", "pod-wo-index-w-ns-index", 1),
("pod-anno", "pod-w-index-wo-ns-index", 1),
("ci_events", "pod-wo-index-wo-ns-index", 1),
])
def test_annotation_routing(setup, container_name, expected):
'''
Expand All @@ -76,7 +76,7 @@ def test_annotation_routing(setup, container_name, expected):
'''
logger.info("testing test_annotation_routing pod={0} expected={1} event(s)".format(
container_name, expected))
search_query = "index=* container_name::" + container_name
search_query = "index=" + index + container_name::" + container_name
events = check_events_from_splunk(start_time="-1h@h",
url=setup["splunkd_url"],
user=setup["splunk_user"],
Expand Down Expand Up @@ -252,7 +252,7 @@ def test_custom_metadata_fields(setup, field,value, expected):

@pytest.mark.parametrize("label,index,value,expected", [
("pod-w-index-wo-ns-index", "pod-anno", "pod-value-2", 1),
("pod-wo-index-w-ns-index", "ns-anno", "ns-value", 1),
# ("pod-wo-index-w-ns-index", "ns-anno", "ns-value", 1),
("pod-w-index-w-ns-index", "pod-anno", "pod-value-1", 1)
])
def test_custom_metadata_fields_annotations(setup, label, index, value, expected):
Expand Down

0 comments on commit e85c41e

Please sign in to comment.