From fdc92dbb02d5f620aa3dd5dc178030fd36d19410 Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Thu, 16 May 2024 13:31:22 -0300 Subject: Move UUID, FatalIf(), events, etc. code to external lib --- tests/lib_test.go | 29 ----------------------------- 1 file changed, 29 deletions(-) (limited to 'tests') diff --git a/tests/lib_test.go b/tests/lib_test.go index 9b7cd9f..71ff6d0 100644 --- a/tests/lib_test.go +++ b/tests/lib_test.go @@ -2,10 +2,6 @@ package papo_test import ( "bufio" - "bytes" - "encoding/json" - "fmt" - "log/slog" "reflect" "strings" "testing" @@ -352,28 +348,3 @@ func TestParseMessage(t *testing.T) { assertEqual(t, given, expected) } - -func TestSetLoggerOutput(t *testing.T) { - return - type entry struct { - msg string `json:"msg"` - aKey string `json:"a-key"` - } - var e entry - var buf bytes.Buffer - papo.SetLoggerOutput(&buf) - slog.Error("the message", "a-key", "a-value") - - s := buf.String() - // fmt.Println(s) - // fmt.Println(e) - err := json.Unmarshal([]byte(s), &e) - if err != nil { - t.Fail() - } - if e.msg != "the message" { - t.Fail() - } - fmt.Println(1) - // fmt.Println(e) -} -- cgit v1.2.3