summaryrefslogtreecommitdiff
path: root/django/test
AgeCommit message (Collapse)Author
2015-02-15[1.8.x] Deprecated TEMPLATE_DEBUG setting.Aymeric Augustin
Backport of 15b711b from master.
2015-02-09[1.8.x] Sorted imports with isort; refs #23860.Tim Graham
Backport of 0ed7d155635da9f79d4dd67e4889087d3673c6da from master
2015-02-08[1.8.x] Called parent in SimpleTestCase.setUpClass/tearDownClass.Aymeric Augustin
Backport of 146dd7be8dad4cd6264d374b681256a8b0d5808b from master
2015-02-04[1.8.x] Fixed #24197 -- Added clearing of staticfiles caches on settings ↵mlavin
changes during tests Cleared caching in staticfiles_storage and get_finder when relevant settings are changed. Backport of 2730dad0d7c425f33f1ecc6cec01fdbf1cdd8376 from master
2015-02-03[1.8.x] Skipped tests from refs #24168 on Python 3.2.Tim Graham
2015-02-03[1.8.x] Fixed #24168 -- Allowed selecting a template engine in a few APIs.Aymeric Augustin
Specifically in rendering shortcuts, template responses, and class-based views that return template responses. Also added a test for render_to_response(status=...) which was missing from fdbfc980. Thanks Tim and Carl for the review. Backport of 2133f31 from master. Conflicts: docs/topics/http/shortcuts.txt tests/generic_views/test_base.py
2015-01-12Fixed #24118 -- Added --debug-sql option for tests.Marc Tamlyn
Added a --debug-sql option for tests and runtests.py which outputs the SQL logger for failing tests. When combined with --verbosity=2, it also outputs the SQL for passing tests. Thanks to Berker, Tim, Markus, Shai, Josh and Anssi for review and discussion.
2015-01-03Removed extraneous super call in LiveServerTestCaseClaude Paroz
Refs #21281. Thanks Tim Graham and Thomas Chaumeny for investigations.
2014-12-30Added ignore_warnings decoratorClaude Paroz
And removed Ignore*DeprecationWarningsMixin, now obsolete. Thanks Berker Peksag and Tim Graham for the review.
2014-12-30Fixed #12118 -- Added shared cache support to SQLite in-memory testing.Andriy Sokolovskiy
2014-12-28Added initial support for loading template engines.Aymeric Augustin
2014-12-24Fixed #20349 -- Moved setting_changed signal to django.core.signals.Collin Anderson
This removes the need to load django.test when not testing.
2014-12-22Fixed #23792 -- Added test.utils.freeze_time() context manager.Thomas Chaumeny
2014-12-14Fixed #23992 -- Optimized reorder_suite functions using OrderedSetThomas Chaumeny
2014-12-12Refs #20392 -- Load fixtures once within TestCaseThomas Chaumeny
2014-12-08Fixed #23968 -- Replaced list comprehension with generators and dict ↵Jon Dufresne
comprehension
2014-12-06Refs #23947 -- Worked around a bug in Python that prevents deprecation ↵Diego Guimarães
warnings from appearing in tests.
2014-12-06Updated obsolete comment.Aymeric Augustin
2014-12-04Fixed #23911 -- Added support for buffer file uploads in the test clientThomas Tanner
2014-12-03Fixed #20392 -- Added TestCase.setUpTestData()Thomas Chaumeny
Each TestCase is also now wrapped in a class-wide transaction.
2014-12-01Fixed #23289 -- Added mock as a test dependency.Tim Graham
2014-12-01Fixed #23933 -- Made override_settings(DATABASE_ROUTERS) affect the master ↵wrwrwr
router.
2014-11-29Fixed #23930 -- Added copies of captured_std* managers from CPython's ↵wrwrwr
test.support. StringIO import was adapted for compatibility with Python 2.
2014-11-25Fixed #23682 -- Enhanced circular redirects detection in tests.wrwrwr
When the test client detects a redirect to a URL seen in the currently followed chain it will now raise a RedirectCycleError instead of just returning the first repeated response. It will also complain when a single chain of redirects is longer than 20, as this often means a redirect loop with varying URLs, and even if it's not actually one, such long chains are likely to be treated as loops by browsers. Thanks Preston Timmons, Berker Peksag, and Tim Graham for reviews.
2014-11-24Fixed #23742 -- Added an option to reverse tests order.wrwrwr
This is useful for debugging side effects affecting tests that are usually executed before a given test. Full suite and pair tests sort cases more or less deterministically, thus some test cross-dependencies are easier to reveal by reversing the order. Thanks Preston Timmons for the review.
2014-11-23Encapsulated TEMPLATE_DEBUG in Engine.Aymeric Augustin
2014-11-23Encapsulated TEMPLATE_CONTEXT_PROCESSORS in Engine.Aymeric Augustin
Since RequestContext doesn't know its Engine until it's passed to Template.render() -- and cannot without breaking a widely used public API -- an elaborate hack is required to apply context processors.
2014-11-23Removed dependency of template loaders on Django settings.Aymeric Augustin
2014-11-23Moved template loaders management in Engine.Aymeric Augustin
Passed the engine instance to loaders. This is a prerequisite for looking up configuration on the engine instance instead of global settings. This is backwards incompatible for custom template loaders that override __init__. However the documentation doesn't talk about __init__ and the way to pass arguments to custom template loaders isn't specified. I'm considering it a private API.
2014-11-23Introduced a template engine class.Aymeric Augustin
Moved Django templates loading infrastructure there.
2014-11-19Simplified caching of template context processors.Aymeric Augustin
2014-11-19Simplified caching of templatetags modules.Aymeric Augustin
2014-11-19Simplified caching of get_default_timezone().Aymeric Augustin
2014-11-16Refactored getting the list of template loaders.Aymeric Augustin
This provides the opportunity to move utility functions specific to the Django Template Language outside of django.template.loader.
2014-11-16Removed override_template_loaders and override_with_test_loader.Aymeric Augustin
They can be replaced with override_settings and that makes the corresponding tests much more obvious.
2014-11-16Refactored listing template subdirectories in apps.Aymeric Augustin
This change has the nice side effect of removing code that ran at import time and depended on the app registry at module level -- a notorious cause of AppRegistryNotReady exceptions.
2014-11-16Moved all template loaders under django.template.loaders.Aymeric Augustin
Reformatted the code of base.Loader according to modern standards. Turned the test template loader into a regular locmem.Loader -- but didn't document it. Added a normal deprecation path for BaseLoader which is a public API. Added an accelerated deprecation path for TestTemplateLoader which is a private API.
2014-11-16Fixed regression in 4dc4d12e. Refs #21598.Aymeric Augustin
That commit contained a mistake that resulted in the use_cached_loader option of override_with_test_loader being ignored. As a consequence some configurations weren't exercised any more by the test suite.
2014-11-10Fixed negligible formatting error.Aymeric Augustin
2014-11-10Removed legacy code from old transaction systemThomas Chaumeny
2014-11-03Fixed #23300 -- Made assertTemplateUsed throw an error on responses not ↵Davide Ceretti
fetched using the test client. Thanks zags for the report and bmispelon for the patch.
2014-11-03Fixed #21281 -- Made override_settings act at class level when used as a ↵Thomas Chaumeny
TestCase decorator.
2014-10-28Fixed #23606 -- Implemented Client and RequestFactory trace() methods.Rigel Di Scala
Thanks KevinEtienne for the suggestion.
2014-10-23Fixed #23707 -- Prevented discovery of duplicated testsClaude Paroz
2014-10-21Fixed #21740 -- Allowed test client data to be an empty stringClaude Paroz
This fixes a regression introduced by 2a31d00933. Thanks tony-zhu for the report.
2014-10-20Removed redundant skip_checks option for call_commandClaude Paroz
2014-10-16Fixed #19508 -- Implemented uri_to_iri as per RFC.Anubhav Joshi
Thanks Loic Bistuer for helping in shaping the patch and Claude Paroz for the review.
2014-10-08Fixed #23600 -- Made default_storage aware of more settings changes.Duncan Parkes
Added MEDIA_URL, FILE_UPLOAD_PERMISSIONS, and FILE_UPLOAD_DIRECTORY_PERMISSIONS to the list of settings.
2014-09-29Fixed #23567 -- Made assertQuerysetEqual check Counter equality when ↵Thomas Chaumeny
ordered=False
2014-09-29Replaced set([foo, ...]) by {foo, ...} literals. Refs PR 3282.Thomas Chaumeny
Thanks Collin Anderson for the review.