mirror of
https://github.com/django/django.git
synced 2024-11-29 22:56:46 +01:00
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.
This commit is contained in:
parent
dec93d8991
commit
cffa559082
@ -238,9 +238,11 @@ class override_with_test_loader(override_template_loaders):
|
||||
@classmethod
|
||||
def _get_loader(cls, templates_dict, use_cached_loader=False):
|
||||
if use_cached_loader:
|
||||
loader = cached.Loader(('TestTemplateLoader',))
|
||||
loader._cached_loaders = TestTemplateLoader(templates_dict)
|
||||
return TestTemplateLoader(templates_dict)
|
||||
loader = cached.Loader(['TestTemplateLoader'])
|
||||
loader._cached_loaders = [TestTemplateLoader(templates_dict)]
|
||||
return loader
|
||||
else:
|
||||
return TestTemplateLoader(templates_dict)
|
||||
|
||||
|
||||
class override_settings(object):
|
||||
|
Loading…
Reference in New Issue
Block a user