'The order of template loader works. Refs #21460.'

def test_cached_loader_priority(self):

    loaders = [('django.template.loaders.cached.Loader', ['django.template.loaders.filesystem.Loader', 'django.template.loaders.app_directories.Loader'])]
    engine = Engine(dirs=[OTHER_DIR, TEMPLATE_DIR], loaders=loaders)
    template = engine.get_template('priority/foo.html')
    self.assertEqual(template.render(Context()), 'priority\n')
    template = engine.get_template('priority/foo.html')
    self.assertEqual(template.render(Context()), 'priority\n')
