Skip to content

Commit aa3056c

Browse files
committed
more time
1 parent 1f1aac7 commit aa3056c

File tree

1 file changed

+2
-11
lines changed

1 file changed

+2
-11
lines changed

internal/pkg/otel/samples_test.go

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ import (
1616
"go.opentelemetry.io/collector/otelcol"
1717
"go.uber.org/zap"
1818
"go.uber.org/zap/zapcore"
19-
"go.uber.org/zap/zaptest/observer"
2019
)
2120

2221
func TestSamples(t *testing.T) {
@@ -46,17 +45,9 @@ func TestSamples(t *testing.T) {
4645
}
4746

4847
func testSample(t *testing.T, configFile string) {
49-
base, obs := observer.New(zapcore.DebugLevel)
50-
t.Cleanup(func() {
51-
if t.Failed() {
52-
for _, log := range obs.All() {
53-
t.Logf("%+v", log)
54-
}
55-
}
56-
})
5748
settings := NewSettings("test", []string{configFile})
5849
settings.LoggingOptions = []zap.Option{zap.WrapCore(func(zapcore.Core) zapcore.Core {
59-
return base
50+
return zapcore.NewNopCore()
6051
})}
6152
collector, err := otelcol.NewCollector(*settings)
6253
assert.NoError(t, err)
@@ -66,7 +57,7 @@ func testSample(t *testing.T, configFile string) {
6657

6758
assert.Eventually(t, func() bool {
6859
return otelcol.StateRunning == collector.GetState()
69-
}, 10*time.Second, 200*time.Millisecond)
60+
}, 20*time.Second, 200*time.Millisecond)
7061
collector.Shutdown()
7162
wg.Wait()
7263
assert.Equal(t, otelcol.StateClosed, collector.GetState())

0 commit comments

Comments
 (0)