test: add clear-search URL and template tests
Add tests for clear_search_url context and template clear-search button when a search is active.
This commit is contained in:
@@ -169,6 +169,9 @@ def render_directory(request, path_text, full_path):
|
||||
"search_action_url": gallery_url(
|
||||
Path(path_text) if path_text != "" else None, True, search_action_query
|
||||
),
|
||||
"clear_search_url": gallery_url(
|
||||
Path(path_text) if path_text != "" else None, True, None
|
||||
),
|
||||
}
|
||||
|
||||
# sort_label depends on SORT_LABELS in common; import lazily to avoid circulars
|
||||
|
||||
Reference in New Issue
Block a user