1
0
mirror of https://github.com/golang/go synced 2024-11-18 23:05:06 -07:00

testing/slogtest: clarify that passed handler must be enabled at info

Fixes #62115.

Change-Id: I1ecd3048ccbf2014bc1d561c7cd79a0c2fe8e4bd
Reviewed-on: https://go-review.googlesource.com/c/go/+/520676
Run-TryBot: Jonathan Amsterdam <jba@google.com>
Reviewed-by: Alan Donovan <adonovan@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
This commit is contained in:
Jonathan Amsterdam 2023-08-17 16:00:08 -04:00
parent eaae2d45c7
commit e016fabb55

View File

@ -36,6 +36,7 @@ type testCase struct {
//
// TestHandler installs the given Handler in a [slog.Logger] and
// makes several calls to the Logger's output methods.
// The Handler should be enabled for levels Info and above.
//
// The results function is invoked after all such calls.
// It should return a slice of map[string]any, one for each call to a Logger output method.