From d5ac1c646505d448d112f74e5c1b4d1b05903fda Mon Sep 17 00:00:00 2001 From: Stefan Haller Date: Thu, 23 Nov 2023 20:22:16 +0100 Subject: [PATCH] fixup! Add pprofLabelForThreadNames config --- service/dap/server_test.go | 37 +++++++------------------------------ 1 file changed, 7 insertions(+), 30 deletions(-) diff --git a/service/dap/server_test.go b/service/dap/server_test.go index 660bee9c25..9708f4f098 100644 --- a/service/dap/server_test.go +++ b/service/dap/server_test.go @@ -1401,36 +1401,13 @@ func TestGoroutineLabels(t *testing.T) { showPprofLabelsConfig []string expectedPrefixWithLabel string }{ - { - []string{}, - "* [Go 1]", - }, - { - []string{"k1"}, - "* [Go 1 v1]", - }, - { - []string{"k2"}, - "* [Go 1 v2]", - }, - { - // When passing keys explicitly, we show them in the given order - []string{"k2", "k1"}, - "* [Go 1 k2:v2 k1:v1]", - }, - { - []string{"unknown"}, - "* [Go 1]", - }, - { - []string{"unknown", "k1"}, - "* [Go 1 k1:v1]", - }, - { - // Special case for showing all labels; labels are shown sorted by key - []string{"*"}, - "* [Go 1 k1:v1 k2:v2]", - }, + {[]string{}, "* [Go 1]"}, + {[]string{"k1"}, "* [Go 1 v1]"}, + {[]string{"k2"}, "* [Go 1 v2]"}, + {[]string{"k2", "k1"}, "* [Go 1 k2:v2 k1:v1]"}, // When passing keys explicitly, we show them in the given order + {[]string{"unknown"}, "* [Go 1]"}, + {[]string{"unknown", "k1"}, "* [Go 1 k1:v1]"}, + {[]string{"*"}, "* [Go 1 k1:v1 k2:v2]"}, // Special case for showing all labels; labels are shown sorted by key } for _, tc := range tests { runTest(t, "goroutineLabels", func(client *daptest.Client, fixture protest.Fixture) {