(t *testing.T)
| 74 | } |
| 75 | |
| 76 | func TestGetHook(t *testing.T) { |
| 77 | router, _, err := setupRouter(t) |
| 78 | if err != nil { |
| 79 | t.Fatalf("Failed to setup router: %v", err) |
| 80 | } |
| 81 | |
| 82 | t.Run("Hook not found", func(t *testing.T) { |
| 83 | req := httptest.NewRequest("GET", "/hooks/hk_nonexistent", nil) |
| 84 | resp := httptest.NewRecorder() |
| 85 | router.ServeHTTP(resp, req) |
| 86 | assert.Equal(t, http.StatusNotFound, resp.Code) |
| 87 | }) |
| 88 | } |
| 89 | |
| 90 | func TestListHooks(t *testing.T) { |
| 91 | router, _, err := setupRouter(t) |
nothing calls this directly
no test coverage detected