From 968397228fe03968bb855856532569586c8a8a1c Mon Sep 17 00:00:00 2001 From: sai-ganesh-03 Date: Thu, 31 Oct 2024 19:10:00 +0530 Subject: Fixed #35867, Refs #2411 -- Allowed links in admindocs view details summary. --- tests/admin_docs/test_views.py | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'tests/admin_docs/test_views.py') diff --git a/tests/admin_docs/test_views.py b/tests/admin_docs/test_views.py index 064ce27fb0..c48a89a1b0 100644 --- a/tests/admin_docs/test_views.py +++ b/tests/admin_docs/test_views.py @@ -89,6 +89,18 @@ class AdminDocViewTests(TestDataMixin, AdminDocsTestCase): # View docstring self.assertContains(response, "Base view for admindocs views.") + def testview_docstring_links(self): + summary = ( + '

This is a view for ' + '' + "myapp.Company

" + ) + url = reverse( + "django-admindocs-views-detail", args=["admin_docs.views.CompanyView"] + ) + response = self.client.get(url) + self.assertContains(response, summary, html=True) + @override_settings(ROOT_URLCONF="admin_docs.namespace_urls") def test_namespaced_view_detail(self): url = reverse( @@ -408,9 +420,9 @@ class TestModelDetailView(TestDataMixin, AdminDocsTestCase): def test_model_docstring_renders_correctly(self): summary = ( - '

Stores information about a person, related to ' + '

Stores information about a person, related to ' '' - "myapp.Company.

" + "myapp.Company." ) subheading = "

Notes

" body = ( -- cgit v1.3