From 2f9f2afbab47cf731d7b6051383cd23ad4e23b6a Mon Sep 17 00:00:00 2001
From: Victor Conner <victor@conner.dev>
Date: Sun, 26 May 2024 14:35:05 +0200
Subject: [PATCH] fix: Wait before asserting panic cleanup (#12)

---
 inflight_test.go | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/inflight_test.go b/inflight_test.go
index 6216634..34c103f 100644
--- a/inflight_test.go
+++ b/inflight_test.go
@@ -146,6 +146,8 @@ func TestInflightKeysAreRemovedForBatchRequestsThatPanic(t *testing.T) {
 		t.Errorf("expected an error; got nil")
 	}
 
+	time.Sleep(50 * time.Millisecond)
+
 	if c.NumKeysInflight() > 0 {
 		t.Errorf("expected no inflight keys; got %d", c.NumKeysInflight())
 	}