diff --git a/receiver/prometheusreceiver/config_test.go b/receiver/prometheusreceiver/config_test.go index c2c79dfe0c982..bdbadf08ecef9 100644 --- a/receiver/prometheusreceiver/config_test.go +++ b/receiver/prometheusreceiver/config_test.go @@ -78,6 +78,7 @@ func TestLoadTargetAllocatorConfig(t *testing.T) { assert.Equal(t, "http://localhost:8080", r0.TargetAllocator.Endpoint) assert.Equal(t, 5*time.Second, r0.TargetAllocator.Timeout) assert.Equal(t, "client.crt", r0.TargetAllocator.TLS.CertFile) + assert.Equal(t, "client.key", r0.TargetAllocator.TLS.KeyFile) assert.Equal(t, 30*time.Second, r0.TargetAllocator.Interval) assert.Equal(t, "collector-1", r0.TargetAllocator.CollectorID) assert.NotNil(t, r0.PrometheusConfig) diff --git a/receiver/prometheusreceiver/testdata/config_target_allocator.yaml b/receiver/prometheusreceiver/testdata/config_target_allocator.yaml index 9c708ed58de5b..27010c225e4c1 100644 --- a/receiver/prometheusreceiver/testdata/config_target_allocator.yaml +++ b/receiver/prometheusreceiver/testdata/config_target_allocator.yaml @@ -4,6 +4,7 @@ prometheus: timeout: 5s tls: cert_file: "client.crt" + key_file: "client.key" interval: 30s collector_id: collector-1 prometheus/withScrape: diff --git a/receiver/prometheusreceiver/testdata/invalid-config-prometheus-target-allocator.yaml b/receiver/prometheusreceiver/testdata/invalid-config-prometheus-target-allocator.yaml index 6afe8bb11d8f3..e7cecaacb61b2 100644 --- a/receiver/prometheusreceiver/testdata/invalid-config-prometheus-target-allocator.yaml +++ b/receiver/prometheusreceiver/testdata/invalid-config-prometheus-target-allocator.yaml @@ -4,6 +4,7 @@ prometheus: timeout: 5s tls: cert_file: "client.crt" + key_file: "client.key" interval: 30s collector_id: collector-1 http_scrape_config: