'Ensure that one can use a custom template to render an admin filter.
Refs #17515.'

def test_filter_with_custom_template(self):

    template_dirs = (settings.TEMPLATE_DIRS + (os.path.join(os.path.dirname(upath(__file__)), u'templates'),))
    with self.settings(TEMPLATE_DIRS=template_dirs):
        response = self.client.get(u'/test_admin/admin/admin_views/color2/')
        self.assertTemplateUsed(response, u'custom_filter_template.html')
