Skip to content

Commit

Permalink
added field name test case
Browse files Browse the repository at this point in the history
  • Loading branch information
lmittmann committed Jan 18, 2024
1 parent 2027ee7 commit 5f26a28
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions handler_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,15 @@ func TestHandler(t *testing.T) {
},
Want: `Nov 10 23:00:00.000 ERR test group.err=fail`,
},
{ // https://github.com/lmittmann/tint/issues/55
F: func(l *slog.Logger) {
l.Info("test", "key", struct {
A int
B *string
}{A: 123})
},
Want: `Nov 10 23:00:00.000 INF test key="{A:123 B:<nil>}"`,
},
}

for i, test := range tests {
Expand Down

0 comments on commit 5f26a28

Please sign in to comment.