private/testplanet: use info level logs in jenkins
Change-Id: Ie500a7bfcd23ca7470139341e961b2e9986d6a33
This commit is contained in:
parent
b1d9a4426f
commit
56c668a2e3
@ -186,6 +186,7 @@ pipeline {
|
||||
'cockroach://root@localhost:26259/testcockroach?sslmode=disable'
|
||||
STORJ_TEST_COCKROACH_ALT = 'cockroach://root@localhost:26260/testcockroach?sslmode=disable'
|
||||
STORJ_TEST_POSTGRES = 'postgres://postgres@localhost/teststorj?sslmode=disable'
|
||||
STORJ_TEST_LOG_LEVEL = 'info'
|
||||
COVERFLAGS = "${ env.BRANCH_NAME == 'main' ? '-coverprofile=.build/coverprofile -coverpkg=storj.io/storj/private/...,storj.io/storj/satellite/...,storj.io/storj/storage/...,storj.io/storj/storagenode/...,storj.io/storj/versioncontrol/...' : ''}"
|
||||
}
|
||||
steps {
|
||||
|
@ -35,10 +35,17 @@ func NewLogger(t *testing.T) *zap.Logger {
|
||||
|
||||
enc.AppendString(fmt.Sprintf("%02d:%02d.%03d", minutes, seconds, nanos/1e6))
|
||||
}
|
||||
|
||||
enc := zapcore.NewConsoleEncoder(cfg)
|
||||
writer := newTestingWriter(t)
|
||||
level := zapcore.DebugLevel
|
||||
|
||||
if l := os.Getenv("STORJ_TEST_LOG_LEVEL"); l != "" {
|
||||
_ = level.Set(l)
|
||||
}
|
||||
|
||||
return zap.New(
|
||||
zapcore.NewCore(enc, writer, zapcore.DebugLevel),
|
||||
zapcore.NewCore(enc, writer, level),
|
||||
zap.ErrorOutput(writer.WithMarkFailed(true)),
|
||||
)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user