diff options
| author | Tim Graham <timograham@gmail.com> | 2015-09-03 15:52:04 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2015-09-23 19:31:10 -0400 |
| commit | 5e450c52aafb62b9d83c8ac08892e0b92cbec4aa (patch) | |
| tree | dbc6b0360aba68d492dc0925d527c9c0f237f401 /tests/template_tests/test_response.py | |
| parent | 75374d3797c2cd2423982a870bb0bc74821e951f (diff) | |
Removed current_app argument to render() and TemplateResponse().
Per deprecation timeline.
Diffstat (limited to 'tests/template_tests/test_response.py')
| -rw-r--r-- | tests/template_tests/test_response.py | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/tests/template_tests/test_response.py b/tests/template_tests/test_response.py index 36a0ba704d..8fea389f53 100644 --- a/tests/template_tests/test_response.py +++ b/tests/template_tests/test_response.py @@ -282,11 +282,6 @@ class TemplateResponseTest(SimpleTestCase): response = TemplateResponse(request, 'template_tests/using.html', using='jinja2').render() self.assertEqual(response.content, b'Jinja2\n') - @ignore_warnings(category=RemovedInDjango110Warning) - def test_custom_app(self): - self._response('{{ foo }}', current_app="foobar") - self.assertEqual(self._request.current_app, 'foobar') - def test_pickling(self): # Create a template response. The context is # known to be unpickleable (e.g., a function). @@ -310,8 +305,12 @@ class TemplateResponseTest(SimpleTestCase): # ...and the unpickled response doesn't have the # template-related attributes, so it can't be re-rendered - template_attrs = ('template_name', 'context_data', - '_post_render_callbacks', '_request', '_current_app') + template_attrs = ( + 'template_name', + 'context_data', + '_post_render_callbacks', + '_request', + ) for attr in template_attrs: self.assertFalse(hasattr(unpickled_response, attr)) |
