From f67c4605fd9c53830940e172158a9ffc1b30b292 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sascha=20I=C3=9Fbr=C3=BCcker?= Date: Sun, 25 Jan 2026 11:44:48 +0100 Subject: [PATCH] Fix URL not updating on tag search --- bookmarks/templates/tags/index.html | 2 +- .../tests_e2e/e2e_test_tag_management.py | 25 +++++++++++++++++++ 2 files changed, 26 insertions(+), 1 deletion(-) diff --git a/bookmarks/templates/tags/index.html b/bookmarks/templates/tags/index.html index d2dfdd2..cc70e0e 100644 --- a/bookmarks/templates/tags/index.html +++ b/bookmarks/templates/tags/index.html @@ -22,7 +22,7 @@ {# Filters #}
-
+
diff --git a/bookmarks/tests_e2e/e2e_test_tag_management.py b/bookmarks/tests_e2e/e2e_test_tag_management.py index 00ccd37..9a4848f 100644 --- a/bookmarks/tests_e2e/e2e_test_tag_management.py +++ b/bookmarks/tests_e2e/e2e_test_tag_management.py @@ -334,3 +334,28 @@ class TagManagementE2ETestCase(LinkdingE2ETestCase): self.assertEqual( Tag.objects.filter(owner=self.get_or_create_test_user()).count(), 2 ) + + def test_search_updates_url_query_params(self): + self.setup_tag(name="python") + self.setup_tag(name="javascript") + self.setup_tag(name="typescript") + + self.open(reverse("linkding:tags.index")) + + # Verify all tags are visible initially + expect(self.locate_tag_row("python")).to_be_visible() + expect(self.locate_tag_row("javascript")).to_be_visible() + expect(self.locate_tag_row("typescript")).to_be_visible() + + # Enter search term and submit + search_input = self.page.get_by_placeholder("Search tags...") + search_input.fill("script") + self.page.get_by_role("button", name="Search").click() + + # Wait for filtered results to appear + expect(self.locate_tag_row("python")).not_to_be_visible() + expect(self.locate_tag_row("javascript")).to_be_visible() + expect(self.locate_tag_row("typescript")).to_be_visible() + + # Verify URL contains search query param + self.assertIn("search=script", self.page.url)