diff options
| author | 2023-05-11 22:32:56 -0700 | |
|---|---|---|
| committer | 2023-05-11 22:32:56 -0700 | |
| commit | e8b63ab623613e290849c36bb97efa2943e1cf33 (patch) | |
| tree | c592334d85dea868ca725e57b30bc221cb1e16b5 /pydis_site/apps/content/tests | |
| parent | Switch to psycopg 3 (diff) | |
| parent | Merge pull request #970 from python-discord/django-rules-ruff (diff) | |
Merge branch 'main' into psycopg3
Diffstat (limited to 'pydis_site/apps/content/tests')
| -rw-r--r-- | pydis_site/apps/content/tests/test_views.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/pydis_site/apps/content/tests/test_views.py b/pydis_site/apps/content/tests/test_views.py index e4f898ef..cfc580c0 100644 --- a/pydis_site/apps/content/tests/test_views.py +++ b/pydis_site/apps/content/tests/test_views.py @@ -387,6 +387,14 @@ class TagViewTests(django.test.TestCase): response.context.get("page") ) + def test_tags_have_no_edit_on_github_link(self): + """Tags should not have the standard edit on GitHub link.""" + # The standard "Edit on GitHub" link should not be displayed on tags + # because they have their own GitHub icon that links there. + Tag.objects.create(name="example", body="Joe William Banks", last_commit=self.commit) + response = self.client.get("/pages/tags/example/") + self.assertNotContains(response, "Edit on GitHub") + def test_tag_root_page(self): """Test the root tag page which lists all tags.""" Tag.objects.create(name="tag-1", last_commit=self.commit) |