jesseduffield.lazygit/pkg/integration/tests/ui
Stefan Haller ec3f681ebf Derive the selection highlight from the context stack
A view drew a selection because something told it to, from four places on
three different schedules: a context being focused, a context losing focus,
a context being activated over another one, and a list being re-rendered.
Whether the flags ended up describing the state of the app depended on
which of those had run last, and the last one to run was often none of
them: a refresh only re-focuses the view that has the focus, so a list
whose contents changed underneath an unfocused panel kept whichever
highlight it happened to have.

Derive both flags instead, in one place, from the two things they mean: a
view shows a selection while its context is on the stack and has something
to select, and the context the user is in shows an active one where the
ones behind it show inactive ones. Nothing else needs to say anything about
highlighting, so nothing else can leave a view saying something untrue
about where the focus is.

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-09-03 21:19:04 +02:00
..
accordion.go Make integration tests using commits more robust 2026-07-09 11:56:27 +02:00
background_refresh_keeps_scroll_position.go Add a test that a background refresh keeps the scroll position 2026-08-14 08:04:13 +02:00
branches_not_first_tab.go Don't show a transient view whose window is not part of the layout 2026-07-17 12:07:24 +02:00
commits_not_first_tab.go Don't show a transient view whose window is not part of the layout 2026-07-17 12:07:24 +02:00
disable_switch_tab_with_panel_jump_keys.go Convert JumpToBlock to a list of multi-key bindings 2026-05-25 15:32:47 +02:00
drag_beyond_viewport.go Add a test for dragging a range selection past the bottom of a panel 2026-08-14 08:04:13 +02:00
empty_menu.go Filter the keybindings menu as you type 2026-08-31 20:41:22 +02:00
filtering_scrolls_selection_into_view.go Add tests for the scroll-into-view regressions we fixed by hand 2026-08-14 08:04:13 +02:00
find_base_commit_for_fixup_scrolls_into_view.go Add tests for the scroll-into-view regressions we fixed by hand 2026-08-14 08:04:13 +02:00
hide_side_panel.go Add integration tests for configuring the side panels 2026-06-23 14:15:18 +02:00
keybinding_suggestions_dont_crash_on_disabled_bindings.go Fix crash when keybindings are disabled that we want to show in the status bar 2026-05-28 19:26:43 +02:00
keybinding_suggestions_when_switching_repos.go Avoid showing <esc> in options map when it doesn't do anything 2025-08-14 17:59:38 +02:00
menu_scroll_position_is_reset.go Add tests for the scroll-into-view regressions we fixed by hand 2026-08-14 08:04:13 +02:00
mode_specific_keybinding_suggestions.go Make integration tests using commits more robust 2026-07-09 11:56:27 +02:00
move_commit_scrolls_selection_into_view.go Add tests for the scroll-into-view regressions we fixed by hand 2026-08-14 08:04:13 +02:00
open_link_failure.go Use our new hyperlink support in the information view 2024-08-24 10:36:01 +02:00
page_up_and_down.go Add a test for paging up and down in a list 2026-08-14 08:04:13 +02:00
promote_tab_to_side_panel.go Add integration tests for configuring the side panels 2026-06-23 14:15:18 +02:00
range_select.go Create a range selection by dragging with the mouse in list views 2026-07-31 08:32:43 +02:00
range_select_with_autoscroll.go Keep range drags moving at panel edges 2026-07-31 08:32:43 +02:00
reload_side_panels.go Re-apply the side panel config on a live config reload 2026-06-23 14:15:18 +02:00
reorder_side_panels.go Add integration tests for configuring the side panels 2026-06-23 14:15:18 +02:00
sub_commits_scroll_position_is_reset.go Add tests for the scroll-into-view regressions we fixed by hand 2026-08-14 08:04:13 +02:00
suggestions_selection_follows_the_focus.go Cover how a view's selection follows the focus in and out of a context 2026-09-03 21:19:04 +02:00
switch_repo_moves_the_selection.go Cover how a view's selection follows the focus in and out of a context 2026-09-03 21:19:04 +02:00
switch_tab_from_menu.go Remove OptionMenuAlt1 2026-05-25 15:18:18 +02:00
switch_tab_with_panel_jump_keys.go Convert JumpToBlock to a list of multi-key bindings 2026-05-25 15:32:47 +02:00
toggle_whitespace_keeps_unfocused_selection_dimmed.go Re-render the main view without re-focusing the panel beneath it 2026-09-03 21:19:04 +02:00
unfocused_list_hides_selection_when_emptied.go Derive the selection highlight from the context stack 2026-09-03 21:19:04 +02:00
unfocused_list_shows_selection_when_filled.go Derive the selection highlight from the context stack 2026-09-03 21:19:04 +02:00