(t *testing.T)
| 131 | } |
| 132 | |
| 133 | func TestHTTPStatusesWrapper(t *testing.T) { |
| 134 | assert := New(t) |
| 135 | mockAssert := New(new(testing.T)) |
| 136 | |
| 137 | assert.Equal(mockAssert.HTTPSuccess(httpOK, "GET", "/", nil), true) |
| 138 | assert.Equal(mockAssert.HTTPSuccess(httpRedirect, "GET", "/", nil), false) |
| 139 | assert.Equal(mockAssert.HTTPSuccess(httpError, "GET", "/", nil), false) |
| 140 | |
| 141 | assert.Equal(mockAssert.HTTPRedirect(httpOK, "GET", "/", nil), false) |
| 142 | assert.Equal(mockAssert.HTTPRedirect(httpRedirect, "GET", "/", nil), true) |
| 143 | assert.Equal(mockAssert.HTTPRedirect(httpError, "GET", "/", nil), false) |
| 144 | |
| 145 | assert.Equal(mockAssert.HTTPError(httpOK, "GET", "/", nil), false) |
| 146 | assert.Equal(mockAssert.HTTPError(httpRedirect, "GET", "/", nil), false) |
| 147 | assert.Equal(mockAssert.HTTPError(httpError, "GET", "/", nil), true) |
| 148 | } |
| 149 | |
| 150 | func httpHelloName(w http.ResponseWriter, r *http.Request) { |
| 151 | name := r.FormValue("name") |
nothing calls this directly
no test coverage detected
searching dependent graphs…