test_logger

package
v0.0.0-...-82a4714 Latest Latest
Warning

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

Go to latest
Published: May 6, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() logger.Logger

This logger prevents testing framework from printing the path and line number inside the logger package, which is not useful and clutters the logs. Instead, it will print the caller of the logger (i.e. the line in this test file where the log was called).

func NewObserved

func NewObserved() (logger.Logger, *observer.ObservedLogs)

This logger is used for tests that need to assert on the logs. It combines the console logger with an observer core, which allows us to capture the logs and make assertions on them in the tests.

Types

This section is empty.

Jump to

Keyboard shortcuts

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