aboutsummaryrefslogtreecommitdiffstats
path: root/rest_framework/tests
diff options
context:
space:
mode:
authorXavier Ordoquy2014-03-07 16:11:51 +0100
committerXavier Ordoquy2014-03-07 16:11:51 +0100
commit0e677e9dd178ae7a0250829729a666b54f4eac61 (patch)
tree54678f5837685c73183f192011157ae9cea556e2 /rest_framework/tests
parent6cf19fa4ef1942c84546322aedd371ba87c0ed5f (diff)
downloaddjango-rest-framework-0e677e9dd178ae7a0250829729a666b54f4eac61.tar.bz2
Reintroduced url arguments in the urls for the tests.
Diffstat (limited to 'rest_framework/tests')
-rw-r--r--rest_framework/tests/test_testing.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/rest_framework/tests/test_testing.py b/rest_framework/tests/test_testing.py
index 71bd8b55..a55d4b22 100644
--- a/rest_framework/tests/test_testing.py
+++ b/rest_framework/tests/test_testing.py
@@ -152,3 +152,13 @@ class TestAPIRequestFactory(TestCase):
simple_png.name = 'test.png'
factory = APIRequestFactory()
factory.post('/', data={'image': simple_png})
+
+ def test_request_factory_url_arguments(self):
+ """
+ This is a non regression test against #1461
+ """
+ factory = APIRequestFactory()
+ request = factory.get('/view/?demo=test')
+ self.assertEqual(dict(request.GET), {'demo': ['test']})
+ request = factory.get('/view/', {'demo': 'test'})
+ self.assertEqual(dict(request.GET), {'demo': ['test']})