MCPcopy Index your code
hub / github.com/coder/coder / TestHealthz

Function TestHealthz

coderd/coderd_test.go:248–261  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

246}
247
248func TestHealthz(t *testing.T) {
249 t.Parallel()
250 client := coderdtest.New(t, nil)
251
252 res, err := client.Request(context.Background(), http.MethodGet, "/healthz", nil)
253 require.NoError(t, err)
254 defer res.Body.Close()
255
256 require.Equal(t, http.StatusOK, res.StatusCode)
257 body, err := io.ReadAll(res.Body)
258 require.NoError(t, err)
259
260 assert.Equal(t, "OK", string(body))
261}
262
263func TestSwagger(t *testing.T) {
264 t.Parallel()

Callers

nothing calls this directly

Calls 5

NewFunction · 0.92
CloseMethod · 0.65
RequestMethod · 0.45
EqualMethod · 0.45
ReadAllMethod · 0.45

Tested by

no test coverage detected