logger

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2026 License: Apache-2.0 Imports: 2 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package logger provides internal logging utilities.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewFailTestLogger

func NewFailTestLogger(t *testing.T) logger.Logger

NewFailTestLogger creates a new test logger that fails on errors or warnings.

Types

type FailTestLogger

type FailTestLogger struct {
	// contains filtered or unexported fields
}

FailTestLogger is a logger that fails tests when the application emits warnings or errors. Use this in tests to assert that application code doesn't produce unexpected warnings/errors.

func (*FailTestLogger) Debug

func (l *FailTestLogger) Debug(msg string, args ...any)

Debug is a no-op. Debug logs are expected and don't indicate problems.

func (*FailTestLogger) Error

func (l *FailTestLogger) Error(msg string, args ...any)

Error fails the test. Application code should not emit errors during tests.

func (*FailTestLogger) Info

func (l *FailTestLogger) Info(msg string, args ...any)

Info is a no-op. Info logs are expected and don't indicate problems.

func (*FailTestLogger) Warn

func (l *FailTestLogger) Warn(msg string, args ...any)

Warn fails the test. Application code should not emit warnings during tests.

Jump to

Keyboard shortcuts

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