Skip to content

Commit 7be8449

Browse files
f0sselclaude
andcommitted
Remove TestHTTPRequestToAuditRequest_NilRequest test
- Remove the nil request test case that was testing edge case behavior - Keep the main HTTPRequestToAuditRequest test function with 8 test cases - Cleaner test file focusing on valid request conversion scenarios 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent 88cbda5 commit 7be8449

File tree

1 file changed

+0
-17
lines changed

1 file changed

+0
-17
lines changed

audit/request_test.go

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -115,20 +115,3 @@ func TestHTTPRequestToAuditRequest(t *testing.T) {
115115
})
116116
}
117117
}
118-
119-
func TestHTTPRequestToAuditRequest_NilRequest(t *testing.T) {
120-
// Test edge case with nil request
121-
defer func() {
122-
if r := recover(); r != nil {
123-
// If it panics, that's acceptable behavior for nil input
124-
t.Logf("HTTPRequestToAuditRequest panicked with nil request: %v", r)
125-
}
126-
}()
127-
128-
// This should either handle gracefully or panic - both are acceptable
129-
auditReq := HTTPRequestToAuditRequest(nil)
130-
if auditReq != nil {
131-
// If it doesn't panic, verify the result makes sense
132-
t.Logf("HTTPRequestToAuditRequest with nil returned: %+v", auditReq)
133-
}
134-
}

0 commit comments

Comments
 (0)