Skip to content

Commit 237d0d9

Browse files
committed
enable profiling for linux
1 parent 0fe57f8 commit 237d0d9

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

internal/pkg/otel/samples_test.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import (
1313
"time"
1414

1515
"github.com/stretchr/testify/assert"
16+
"go.opentelemetry.io/collector/featuregate"
1617
"go.opentelemetry.io/collector/otelcol"
1718
"go.uber.org/zap"
1819
"go.uber.org/zap/zapcore"
@@ -30,6 +31,11 @@ func TestSamples(t *testing.T) {
3031
t.Setenv("AUTOOPS_TEMP_RESOURCE_ID", "temp")
3132
t.Setenv("AUTOOPS_OTEL_URL", "http://localhost:4318")
3233

34+
assert.NoError(t, featuregate.GlobalRegistry().Set("service.profilesSupport", true))
35+
defer func() {
36+
assert.NoError(t, featuregate.GlobalRegistry().Set("service.profilesSupport", false))
37+
}()
38+
3339
err := filepath.WalkDir(filepath.Join(".", "samples", runtime.GOOS), func(path string, d os.DirEntry, err error) error {
3440
if err != nil {
3541
return err

0 commit comments

Comments
 (0)