From 101039be9dc1f772ebb8498b8d574d626e44aaba Mon Sep 17 00:00:00 2001 From: Aaron Crickenberger Date: Tue, 2 May 2017 13:33:55 -0700 Subject: [PATCH] skip procfs-dependent metrics test if not on linux --- test/integration/metrics/metrics_test.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/test/integration/metrics/metrics_test.go b/test/integration/metrics/metrics_test.go index b6906ab3d194..23b4f9be1cc9 100644 --- a/test/integration/metrics/metrics_test.go +++ b/test/integration/metrics/metrics_test.go @@ -21,6 +21,7 @@ import ( "fmt" "net/http" "net/http/httptest" + "runtime" "testing" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -85,6 +86,10 @@ func checkForExpectedMetrics(t *testing.T, metrics []*prometheuspb.MetricFamily, } func TestMasterProcessMetrics(t *testing.T) { + if runtime.GOOS == "darwin" || runtime.GOOS == "windows" { + t.Skipf("not supported on GOOS=%s", runtime.GOOS) + } + _, s := framework.RunAMaster(nil) defer s.Close() @@ -95,7 +100,6 @@ func TestMasterProcessMetrics(t *testing.T) { checkForExpectedMetrics(t, metrics, []string{ "process_start_time_seconds", "process_cpu_seconds_total", - "go_goroutines", "process_open_fds", "process_resident_memory_bytes", })