MCPcopy Index your code
hub / github.com/imroc/req / assertStatus

Function assertStatus

req_test.go:348–354  ·  view source on GitHub ↗
(t *testing.T, resp *Response, err error, statusCode int, status string)

Source from the content-addressed store, hash-verified

346}
347
348func assertStatus(t *testing.T, resp *Response, err error, statusCode int, status string) {
349 tests.AssertNoError(t, err)
350 tests.AssertNotNil(t, resp)
351 tests.AssertNotNil(t, resp.Body)
352 tests.AssertEqual(t, statusCode, resp.StatusCode)
353 tests.AssertEqual(t, status, resp.Status)
354}
355
356func assertSuccess(t *testing.T, resp *Response, err error) {
357 tests.AssertNoError(t, err)

Callers 1

TestBadRequestFunction · 0.85

Calls 3

AssertNoErrorFunction · 0.92
AssertNotNilFunction · 0.92
AssertEqualFunction · 0.92

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…