Changeset 1277
- Timestamp:
- 11/17/05 09:55:04 (3 years ago)
- Files:
-
- django/trunk/tests/othertests/templates.py (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
django/trunk/tests/othertests/templates.py
r1068 r1277 1 import traceback 2 1 3 from django.core import template 2 4 from django.core.template import loader 3 from django.utils.translation import activate, deactivate 5 from django.utils.translation import activate, deactivate, install 4 6 5 7 # Helper objects for template tests … … 274 276 tests.sort() 275 277 for name, vals in tests: 278 install() 276 279 if 'LANGUAGE_CODE' in vals[1]: 277 280 activate(vals[1]['LANGUAGE_CODE']) 281 else: 282 activate('en-us') 278 283 try: 279 284 output = loader.get_template(name).render(template.Context(vals[1])) … … 284 289 else: 285 290 if verbosity: 291 traceback.print_exc() 286 292 print "Template test: %s -- FAILED. Got %s, exception: %s" % (name, e.__class__, e) 287 293 failed_tests.append(name)
