package testingadapter
import "github.com/jackc/pgx/v5/log/testingadapter"
Package testingadapter provides a logger that writes to a test or benchmark log.
Index ¶
- type Logger
- func NewLogger(l TestingLogger) *Logger
- func (l *Logger) Log(ctx context.Context, level tracelog.LogLevel, msg string, data map[string]any)
- type TestingLogger
Types ¶
type Logger ¶
type Logger struct {
// contains filtered or unexported fields
}
func NewLogger ¶
func NewLogger(l TestingLogger) *Logger
func (*Logger) Log ¶
type TestingLogger ¶
type TestingLogger interface { Log(args ...any) }
TestingLogger interface defines the subset of testing.TB methods used by this adapter.
Source Files ¶
- Version
- v5.4.0
- Published
- Jun 14, 2023
- Platform
- darwin/amd64
- Imports
- 3 packages
- Last checked
- 1 day ago –
Tools for package owners.