1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

Fixed #14936 -- Tweaked the new render shortcut to reflect non-legacy arguments. Thanks to adamv for the report.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@15020 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Russell Keith-Magee
2010-12-22 04:54:10 +00:00
parent 6e75ee2b32
commit 0fef92f6f0
5 changed files with 30 additions and 12 deletions

View File

@@ -90,8 +90,14 @@ def render_view_with_base_context(request):
'bar': 'BAR',
}, context_instance=Context())
def render_view_with_mimetype(request):
def render_view_with_content_type(request):
return render(request, 'debug/render_test.html', {
'foo': 'FOO',
'bar': 'BAR',
}, mimetype='application/x-rendertest')
}, content_type='application/x-rendertest')
def render_view_with_status(request):
return render(request, 'debug/render_test.html', {
'foo': 'FOO',
'bar': 'BAR',
}, status=403)