summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorpjenvey <none@none>2007-07-02 14:17:49 -0700
committerpjenvey <none@none>2007-07-02 14:17:49 -0700
commita2e5c634342c6a233681cbb41eac13c7ed68026d (patch)
treef15d9874d8d785eaaea8a1261d4d93c6ee9a3b92 /tests
parent7c0ea91baf05070b81f323f942fcf0df40987657 (diff)
downloadroutes-a2e5c634342c6a233681cbb41eac13c7ed68026d.tar.gz
[svn] fixed the special '_method' attribute not being recognized during POST requests
of Content-Type 'multipart/form-data' fixes #55 --HG-- branch : trunk
Diffstat (limited to 'tests')
-rw-r--r--tests/test_functional/test_middleware.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/test_functional/test_middleware.py b/tests/test_functional/test_middleware.py
index c38818f..451bc2d 100644
--- a/tests/test_functional/test_middleware.py
+++ b/tests/test_functional/test_middleware.py
@@ -53,3 +53,9 @@ def test_method_conversion():
headers={'Content-Type': 'application/x-www-form-urlencoded'})
assert "matchdict is {'action': u'index', 'controller': u'content', 'type': u'grind'}" in res
assert "'REQUEST_METHOD': 'POST'" in res
+
+ res = app.post('/content/grind',
+ upload_files=[('fileupload', 'hello.txt', 'Hello World')],
+ params={'_method':'DELETE', 'name':'smoth'})
+ assert "matchdict is {'action': u'index', 'controller': u'content', 'type': u'grind'}" in res
+ assert "'REQUEST_METHOD': 'POST'" in res