From 2be57d3d75a79b5eeb5cee178a6be1939d00d2ca Mon Sep 17 00:00:00 2001 From: hellodeloo Date: Fri, 8 Sep 2023 12:19:24 +0200 Subject: [PATCH] feat: update utility classnames --- lacommunaute/forum/tests/tests_views.py | 22 +++---- .../forum_conversation/tests/tests_views.py | 16 ++--- .../tests/tests_views_htmx.py | 10 ++-- .../tests/test_forumupvoteview.py | 4 +- .../forum_upvote/tests/test_postupvoteview.py | 4 +- .../templates/event/event_calendar.html | 2 +- lacommunaute/templates/event/event_form.html | 6 +- lacommunaute/templates/event/event_list.html | 2 +- .../templates/forum/category_forum_list.html | 10 ++-- .../templates/forum/forum_detail.html | 58 +++++++++---------- lacommunaute/templates/forum/forum_list.html | 38 ++++++------ .../forum_attachments/attachment_formset.html | 6 +- .../forum_polls/poll_detail.html | 4 +- .../forum_polls/poll_option_formset.html | 6 +- .../forum_polls/poll_vote_form.html | 14 ++--- .../forum_polls/topic_list_poll_detail.html | 10 ++-- .../topic_list_poll_vote_form.html | 32 +++++----- .../partials/post_certified.html | 16 ++--- .../partials/post_certified_actions.html | 18 +++--- .../partials/post_certified_badge.html | 2 +- .../partials/post_feed.html | 2 +- .../partials/post_feed_form_collapsable.html | 14 ++--- .../forum_conversation/partials/poster.html | 8 +-- .../partials/posts_list.html | 4 +- .../partials/topic_detail_actions.html | 22 +++---- .../partials/topic_filter.html | 16 ++--- .../partials/topic_form.html | 24 ++++---- .../partials/topic_likes.html | 18 +++--- .../partials/topic_tags.html | 2 +- .../forum_conversation/topic_list.html | 38 ++++++------ .../topic_list_newsfeed.html | 40 ++++++------- .../forum_member/forum_profile_detail.html | 8 +-- .../forum_member/join_forum_landing.html | 4 +- .../forum_member/moderator_profiles.html | 8 +-- .../templates/forum_member/profiles.html | 8 +-- .../templates/forum_search/search.html | 16 ++--- .../templates/forum_search/search_form.html | 8 +-- .../templates/forum_upvote/upvote_list.html | 16 ++--- lacommunaute/templates/pages/contact.html | 14 ++--- lacommunaute/templates/pages/home.html | 30 +++++----- .../templates/partials/ask_a_question.html | 18 +++--- lacommunaute/templates/partials/banner.html | 12 ++-- lacommunaute/templates/partials/footer.html | 24 ++++---- .../templates/partials/form_field.html | 6 +- .../partials/form_field_mentions.html | 8 +-- .../partials/header_nav_primary_items.html | 44 +++++++------- lacommunaute/templates/partials/messages.html | 4 +- .../partials/social_share_buttons.html | 2 +- lacommunaute/templates/partials/upvotes.html | 20 +++---- 49 files changed, 358 insertions(+), 360 deletions(-) diff --git a/lacommunaute/forum/tests/tests_views.py b/lacommunaute/forum/tests/tests_views.py index 3649d4883..aecded4c5 100644 --- a/lacommunaute/forum/tests/tests_views.py +++ b/lacommunaute/forum/tests/tests_views.py @@ -128,27 +128,27 @@ def test_has_liked(self): self.client.force_login(self.user) response = self.client.get(self.url) # icon: solid heart - self.assertContains(response, '1') + self.assertContains(response, '1') def test_has_not_liked(self): self.client.force_login(self.user) response = self.client.get(self.url) # icon: regular heart (outlined) - self.assertContains(response, '0') + self.assertContains(response, '0') def test_has_liked_TOPIC_ANNOUNCE(self): TopicFactory(forum=self.forum, poster=self.user, with_post=True, with_like=True, type=Topic.TOPIC_ANNOUNCE) self.client.force_login(self.user) response = self.client.get(self.url) - self.assertContains(response, '1') + self.assertContains(response, '1') def test_has_not_liked_TOPIC_ANNOUNCE(self): TopicFactory(forum=self.forum, poster=self.user, with_post=True, type=Topic.TOPIC_ANNOUNCE) self.client.force_login(self.user) response = self.client.get(self.url) - self.assertContains(response, '0') + self.assertContains(response, '0') def test_anonymous_like(self): params = {"next_url": self.url} @@ -342,7 +342,7 @@ def test_share_buttons(self): response = self.client.get(url) self.assertContains( response, - 'div class="dropdown-menu dropdown-menu-right" aria-labelledby="dropdownMenuSocialShare">', + 'div class="dropdown-menu dropdown-menu-end" aria-labelledby="dropdownMenuSocialShare">', status_code=200, ) @@ -357,7 +357,7 @@ def test_upvote_actions(self): ' rel="nofollow"' ' class="btn btn-sm btn-ico-only btn-link btn-secondary" data-toggle="tooltip" data-placement="top"' ' title="Connectez-vous pour sauvegarder">' - '\n 0' + '\n 0' ) response = self.client.get( reverse("forum_extension:forum", kwargs={"pk": child_forum.pk, "slug": child_forum.slug}) @@ -374,7 +374,7 @@ def test_upvote_actions(self): '\n data-matomo-action="upvote"' '\n data-matomo-option="post"' "\n >" - '\n ' + '\n ' "0" ) response = self.client.get(reverse("forum_extension:forum", kwargs={"pk": child_forum.pk, "slug": forum.slug})) @@ -389,7 +389,7 @@ def test_upvote_actions(self): '\n data-matomo-action="upvote"' '\n data-matomo-option="post"' "\n >" - '\n ' + '\n ' "1" ) response = self.client.get( @@ -405,7 +405,7 @@ def test_upvotes_count(self): reverse("forum_extension:forum", kwargs={"pk": child_forum.pk, "slug": child_forum.slug}) ) self.assertContains( - response, '0', status_code=200 + response, '0', status_code=200 ) child_forum.upvotes.create(voter=self.user) @@ -414,7 +414,7 @@ def test_upvotes_count(self): reverse("forum_extension:forum", kwargs={"pk": child_forum.pk, "slug": child_forum.slug}) ) self.assertContains( - response, '1', status_code=200 + response, '1', status_code=200 ) child_forum.upvotes.create(voter=UserFactory()) @@ -423,5 +423,5 @@ def test_upvotes_count(self): reverse("forum_extension:forum", kwargs={"pk": child_forum.pk, "slug": child_forum.slug}) ) self.assertContains( - response, '2', status_code=200 + response, '2', status_code=200 ) diff --git a/lacommunaute/forum_conversation/tests/tests_views.py b/lacommunaute/forum_conversation/tests/tests_views.py index 9297b3fb2..18ea4e9e7 100644 --- a/lacommunaute/forum_conversation/tests/tests_views.py +++ b/lacommunaute/forum_conversation/tests/tests_views.py @@ -389,13 +389,13 @@ def test_has_liked(self): self.client.force_login(self.poster) response = self.client.get(self.url) # icon: solid heart - self.assertContains(response, '1') + self.assertContains(response, '1') def test_has_not_liked(self): self.client.force_login(self.poster) response = self.client.get(self.url) # icon: regular heart (outlined) - self.assertContains(response, '0') + self.assertContains(response, '0') def test_pluralized_likes(self): self.topic.likers.add(UserFactory()) @@ -405,7 +405,7 @@ def test_pluralized_likes(self): self.client.force_login(self.poster) response = self.client.get(self.url) # icon: regular heart (outlined) - self.assertContains(response, '2') + self.assertContains(response, '2') def test_anonymous_like(self): assign_perm("can_read_forum", AnonymousUser(), self.topic.forum) @@ -425,7 +425,7 @@ def test_post_has_no_upvote(self): response = self.client.get(self.url) self.assertContains( - response, '0', status_code=200 + response, '0', status_code=200 ) def test_post_has_upvote_by_user(self): @@ -435,7 +435,7 @@ def test_post_has_upvote_by_user(self): response = self.client.get(self.url) self.assertContains( - response, '1', status_code=200 + response, '1', status_code=200 ) def test_certified_post_is_highlighted(self): @@ -525,7 +525,7 @@ def test_has_liked(self): self.client.force_login(self.user) response = self.client.get(self.url) # icon: solid heart - self.assertContains(response, '1') + self.assertContains(response, '1') def test_queryset(self): TopicFactory(with_post=True, forum=ForumFactory(kind=ForumKind.PRIVATE_FORUM, with_public_perms=True)) @@ -619,11 +619,11 @@ def test_showmoretopics_url_with_params(self): def test_filter_dropdown_visibility(self): response = self.client.get(self.url) - self.assertContains(response, '