We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b47a577 commit 2508845Copy full SHA for 2508845
djangobench/benchmarks/l10n_render/benchmark.py
@@ -1,8 +1,7 @@
1
import sys
2
3
from django.core.handlers.wsgi import WSGIRequest
4
-from django.shortcuts import render_to_response
5
-from django.template import RequestContext
+from django.shortcuts import render
6
7
from djangobench.utils import run_benchmark
8
@@ -26,9 +25,8 @@ def make_request():
26
25
27
28
def benchmark():
29
- context = RequestContext(req_object)
30
- context['numbers'] = range(0, 200)
31
- render_to_response('list.html', context)
+ context = {'numbers': range(0, 200)}
+ render(req_object, 'list.html', context)
32
33
34
run_benchmark(
0 commit comments