Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssertDeepCopyEqual ¶
AssertDeepCopyEqual checks to see if two variables have the same values but DO NOT share any memory There is currently a special case for `time.loc` (as this code traverses into unexported fields)
func NewJSONLoggerWithOutput ¶ added in v1.11.0
NewJSONLoggerWithOutput returns a *slog.Logger emitting JSON to w with timestamps suppressed, for tests that pin the JSON shape.
func NewLogger ¶
NewLogger returns a *slog.Logger suitable for use in tests. Output goes to io.Discard by default; set TEST_LOGS=1 (info), 2 (debug), or 3 (trace) to stream output to stderr for local debugging.
func NewLoggerWithOutput ¶ added in v1.11.0
NewLoggerWithOutput returns a *slog.Logger whose text output is captured by w. Timestamps are suppressed so tests can assert on exact output without baking the current time into expected strings.
Types ¶
This section is empty.