(wantStatus int)
| 79 | func checks(vv ...check) []check { return vv } |
| 80 | |
| 81 | func httpStatus(wantStatus int) check { |
| 82 | return func(t *testing.T, e *peerAPITestEnv) { |
| 83 | if res := e.rr.Result(); res.StatusCode != wantStatus { |
| 84 | t.Errorf("HTTP response code = %v; want %v", res.Status, wantStatus) |
| 85 | } |
| 86 | } |
| 87 | } |
| 88 | |
| 89 | func bodyContains(sub string) check { |
| 90 | return func(t *testing.T, e *peerAPITestEnv) { |
no test coverage detected
searching dependent graphs…