guestbook/cmd/web/handlers_guestbook_test.go
2025-06-08 21:10:44 -07:00

20 lines
328 B
Go

package main
import (
"net/http"
"testing"
"git.32bit.cafe/32bitcafe/guestbook/internal/assert"
)
func TestPing(t *testing.T) {
app := newTestApplication(t)
ts := newTestServer(t, app.routes())
defer ts.Close()
code, _, body := ts.get(t, "/ping")
assert.Equal(t, code, http.StatusOK)
assert.Equal(t, body, "OK")
}