logging

package
v0.0.0-...-5bf0b86 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 18, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LevelFromEnvironment

func LevelFromEnvironment(ctx context.Context) zapcore.Level

LevelFromEnvironment returns a zap level, based on the environment variable TEST_LOGGER_LEVEL.

func NewContext

func NewContext(parent ...context.Context) context.Context

NewContext returns a context with test logger configured. This is interim logger, that should be replaced by testing.T bound test logger using environment.WithTestLogger func.

func WithTestLogger

func WithTestLogger(ctx context.Context, t zaptest.TestingT, opts ...zaptest.LoggerOption) context.Context

WithTestLogger returns a context with test logger configured.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL