diff options
author | Caio Carrara <ccarrara@thoughtworks.com> | 2016-06-27 16:15:49 -0300 |
---|---|---|
committer | Caio Carrara <ccarrara@thoughtworks.com> | 2016-06-27 16:39:55 -0300 |
commit | 25ad94af467ff0efc3765246ef6a1a6df56efb44 (patch) | |
tree | 19b205cd377c2f58daeaadf0ccdd22bc1e771c7f /service/test/unit/resources | |
parent | b5d564b147807f289e07df4fe32b6f417ce90c98 (diff) |
Explicitly use POST to test csrf
Diffstat (limited to 'service/test/unit/resources')
-rw-r--r-- | service/test/unit/resources/test_root_resource.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/service/test/unit/resources/test_root_resource.py b/service/test/unit/resources/test_root_resource.py index b90e89eb..0e963f02 100644 --- a/service/test/unit/resources/test_root_resource.py +++ b/service/test/unit/resources/test_root_resource.py @@ -89,6 +89,7 @@ class TestRootResource(unittest.TestCase): def test_should_unauthorize_child_resource_ajax_requests_when_csrf_mismatch(self): request = DummyRequest(['/child']) + request.method = 'POST' self._mock_ajax_csrf(request, 'stubbed csrf token') request.getCookie = MagicMock(return_value='mismatched csrf token') |