Skip to content

Commit

Permalink
fix: add test case for metrics endpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
muhlba91 committed Oct 4, 2024
1 parent 96e120f commit 3e8a157
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions cmd/webhook/init/server/server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,21 @@ func TestHealth(t *testing.T) {
executeHealthzTestCases(t, testCases)
}

func TestMetrics(t *testing.T) {
testCases := []testCase{
{
name: "metrics ok",
method: http.MethodGet,
path: "/metrics",
body: "",
expectedStatusCode: http.StatusOK,
expectedBody: "{\"healthy\":true}",
},
}

executeHealthzTestCases(t, testCases)
}

func TestRecords(t *testing.T) {
testCases := []testCase{
{
Expand Down

0 comments on commit 3e8a157

Please sign in to comment.