summaryrefslogtreecommitdiff
path: root/tests/template_tests/syntax_tests/test_basic.py
AgeCommit message (Collapse)Author
2015-08-12Fixed #24257 -- Corrected i18n handling of percent signs.Doug Beck
Refactored tests to use a sample project. Updated extraction: * Removed special handling of single percent signs. * When extracting messages from template text, doubled all percent signs so they are not interpreted by gettext as string format flags. All strings extracted by gettext, if containing a percent sign, will now be labeled "#, python-format". Updated translation: * Used "%%" for "%" in template text before calling gettext. * Updated {% trans %} rendering to restore "%" from "%%".
2015-03-20Cleaned up the template debug implementation.Preston Timmons
This patch does three major things: * Merges the django.template.debug implementation into django.template.base. * Simplifies the debug implementation. The old implementation copied debug information to every token and node. The django_template_source attribute was set in multiple places, some quite hacky, like django.template.defaulttags.ForNode. Debug information is now annotated in two high-level places: * Template.compile_nodelist for errors during parsing * Node.render_annotated for errors during rendering These were chosen because they have access to the template and context as well as to all exceptions that happen during either the parse or render phase. * Moves the contextual line traceback information creation from django.views.debug into django.template.base.Template. The debug views now only deal with the presentation of the debug information.
2015-02-06Sorted imports with isort; refs #23860.Tim Graham
2014-12-28Isolated template tests from Django settings.Aymeric Augustin
2014-12-06Fixed #23958 -- Rewrote filter tests as unit tests.Preston Timmons
2014-12-03Converted recently refactored templates tests to SimpleTestCase.Ramiro Morales
These test methods don't need DB setup/teardown. Refs #23768 and b872134b.
2014-12-02Fixed #23768 -- Rewrote template tests as unit tests.Preston Timmons