aboutsummaryrefslogtreecommitdiffstats
path: root/lib/inets/test
diff options
context:
space:
mode:
authorFredrik Gustafsson <[email protected]>2013-07-01 11:31:21 +0200
committerFredrik Gustafsson <[email protected]>2013-07-01 11:31:21 +0200
commitcc6e4b6ce7c2c82fb3039a9e6d46a2c90fd45cf2 (patch)
treeed3d998c0ea8a734d06151603e6214f2e0c6e1b8 /lib/inets/test
parent4c3b306184d886678d08949bcbe0186af8f984b1 (diff)
parentefe1ba19995df00facc8b8fdf552864ae1b67841 (diff)
downloadotp-cc6e4b6ce7c2c82fb3039a9e6d46a2c90fd45cf2.tar.gz
otp-cc6e4b6ce7c2c82fb3039a9e6d46a2c90fd45cf2.tar.bz2
otp-cc6e4b6ce7c2c82fb3039a9e6d46a2c90fd45cf2.zip
Merge branch 'jwh/httpc_delete_body/OTP-11190' into maint
* jwh/httpc_delete_body/OTP-11190: httpc: Allow content body in DELETE requests
Diffstat (limited to 'lib/inets/test')
-rw-r--r--lib/inets/test/httpc_proxy_SUITE.erl17
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/inets/test/httpc_proxy_SUITE.erl b/lib/inets/test/httpc_proxy_SUITE.erl
index 84db39e76b..ddd23d0c65 100644
--- a/lib/inets/test/httpc_proxy_SUITE.erl
+++ b/lib/inets/test/httpc_proxy_SUITE.erl
@@ -69,6 +69,7 @@ local_proxy_cases() ->
http_post,
http_put,
http_delete,
+ http_delete_body,
http_headers,
http_proxy_auth,
http_doesnotexist,
@@ -262,6 +263,22 @@ http_delete(Config) when is_list(Config) ->
%%--------------------------------------------------------------------
+http_delete_body(doc) ->
+ ["Perform a DELETE request with a content body. The server will not allow it "
+ "but we only test sending the request."];
+http_delete_body(Config) when is_list(Config) ->
+ Method = delete,
+ URL = url("/delete.html", Config),
+ Content = "foo=bar",
+ Request = {URL,[],"application/x-www-form-urlencoded",Content},
+ HttpOpts = [],
+ Opts = [],
+ {ok,{{_,405,_},[_|_],[_|_]}} =
+ httpc:request(Method, Request, HttpOpts, Opts),
+ ok.
+
+%%--------------------------------------------------------------------
+
http_headers(doc) ->
["Use as many request headers as possible"];
http_headers(Config) when is_list(Config) ->