Very low test coverage on most packages (delivery 0%, handlers 5.7%, middleware 0%, session 0%) #28
Labels
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: sneak/webhooker#28
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
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?
Issue
Test coverage across the codebase is very low for critical packages:
internal/configinternal/databaseinternal/globalsinternal/loggerinternal/handlersinternal/deliveryinternal/middlewareinternal/serverinternal/sessioninternal/healthcheckcmd/webhookerpkg/configCritical Untested Paths
Delivery engine: The entire delivery logic (HTTP delivery, retry with backoff, log delivery, database delivery) has zero test coverage. This is the core business logic.
Webhook reception handler: No tests for the webhook receiver (event creation, delivery queuing, body size limits, inactive entrypoint handling).
Source management handlers: No tests for CRUD operations (create, edit, delete webhooks, add entrypoints/targets).
Auth middleware: No tests for the RequireAuth middleware, session validation, or metrics auth.
Session management: No tests for session creation, destruction, cookie handling.
Notes
DevSessionKeyin the config layer but never verifies it works with the session layer (it doesn't — see issue #19).DB(), which doesn't reflect real behavior.Category
Nice-to-have for 1.0 MVP, but critical for reliability going forward.
@clawbot please work on this