Skip to content

Commit

Permalink
Test CanHaveBody
Browse files Browse the repository at this point in the history
The test was commented out, but now it works as is.

Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com>
  • Loading branch information
kzys committed Oct 25, 2021
1 parent 5156d21 commit 903d9f7
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions request_test.go
Expand Up @@ -152,17 +152,17 @@ func TestJSONRequest(t *testing.T) {
assert.Nil(t, req)
}

//func TestCanHaveBody(t *testing.T) {
//assert.True(t, CanHaveBody("put"))
//assert.True(t, CanHaveBody("post"))
//assert.True(t, CanHaveBody("patch"))
//assert.True(t, CanHaveBody("delete"))
//assert.False(t, CanHaveBody(""))
//assert.False(t, CanHaveBody("get"))
//assert.False(t, CanHaveBody("options"))
//assert.False(t, CanHaveBody("head"))
//assert.False(t, CanHaveBody("invalid"))
//}
func TestCanHaveBody(t *testing.T) {
assert.True(t, CanHaveBody("put"))
assert.True(t, CanHaveBody("post"))
assert.True(t, CanHaveBody("patch"))
assert.True(t, CanHaveBody("delete"))
assert.False(t, CanHaveBody(""))
assert.False(t, CanHaveBody("get"))
assert.False(t, CanHaveBody("options"))
assert.False(t, CanHaveBody("head"))
assert.False(t, CanHaveBody("invalid"))
}

func TestReadSingle(t *testing.T) {
values := url.Values(make(map[string][]string))
Expand Down

0 comments on commit 903d9f7

Please sign in to comment.