1
0
mirror of https://github.com/django/django.git synced 2025-10-24 06:06:09 +00:00

Fixed #24128 -- Made admindocs TemplateDetailView respect template_loaders.

Co-Authored-By: Author: Alexander Lazarević <laza@e11bits.com>
This commit is contained in:
Kris Avi
2016-10-26 20:26:36 +03:00
committed by Mariusz Felisiak
parent 1df8983aa3
commit b7154f811f
3 changed files with 21 additions and 2 deletions

View File

@@ -0,0 +1,8 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Template for Test</title>
</head>
<body></body>
</html>

View File

@@ -138,6 +138,12 @@ class AdminDocViewTests(TestDataMixin, AdminDocsTestCase):
html=True,
)
def test_template_detail_loader(self):
response = self.client.get(
reverse("django-admindocs-templates", args=["view_for_loader_test.html"])
)
self.assertContains(response, "view_for_loader_test.html</code></li>")
def test_missing_docutils(self):
utils.docutils_is_available = False
try: