MCPcopy Index your code
hub / github.com/php/frankenphp / testPost

Function testPost

frankenphp_test.go:130–136  ·  view source on GitHub ↗
(url string, body string, handler func(http.ResponseWriter, *http.Request), t *testing.T)

Source from the content-addressed store, hash-verified

128}
129
130func testPost(url string, body string, handler func(http.ResponseWriter, *http.Request), t *testing.T) (string, *http.Response) {
131 t.Helper()
132 req := httptest.NewRequest(http.MethodPost, url, nil)
133 req.Body = io.NopCloser(strings.NewReader(body))
134
135 return testRequest(req, handler, t)
136}
137
138func TestMain(m *testing.M) {
139 flag.Parse()

Callers 2

testInputFunction · 0.85
testLargeRequestFunction · 0.85

Calls 1

testRequestFunction · 0.85

Tested by

no test coverage detected