test: add deadlock regression test for JSONHandler (issue #3) #7
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "clawbot/simplelog:test/jsonhandler-deadlock"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Adds a test that reproduces the deadlock described in #3.
The test spawns a goroutine that calls
slog.Info()withJSONHandlerset as the default handler, then waits 5 seconds for completion. On unfixed code this deadlocks; with the fix from #4 it passes.This can be merged independently or after #4.