help: Add gear menu icons to relative links.

This commit is contained in:
David Rosa
2023-07-25 08:41:30 -05:00
committed by Tim Abbott
parent 195e5b8dc1
commit fa59d4f345
2 changed files with 26 additions and 12 deletions

View File

@@ -388,13 +388,18 @@ class HelpTest(ZulipTestCase):
def test_help_relative_links_for_gear(self) -> None:
result = self.client_get("/help/analytics")
self.assertIn('<a href="/stats">Usage statistics</a>', str(result.content))
self.assertIn(
'<a href="/stats"><i class="fa fa-bar-chart"></i> Usage statistics</a>',
str(result.content),
)
self.assertEqual(result.status_code, 200)
with self.settings(ROOT_DOMAIN_LANDING_PAGE=True):
result = self.client_get("/help/analytics", subdomain="")
self.assertEqual(result.status_code, 200)
self.assertIn("<strong>Usage statistics</strong>", str(result.content))
self.assertIn(
'<strong><i class="fa fa-bar-chart"></i> Usage statistics</strong>', str(result.content)
)
self.assertNotIn("/stats", str(result.content))
def test_help_relative_links_for_stream(self) -> None: