...

Package testutil

import "golang.org/x/exp/slog/internal/testutil"
Overview
Index

Overview ▾

Package testutil contains support functions for testing.

func RemoveTime

func RemoveTime(groups []string, a slog.Attr) slog.Attr

RemoveTime removes the top-level time attribute. It is intended to be used as a ReplaceAttr function, to make example output deterministic.