diff options
| author | Paul Buetow <paul@buetow.org> | 2026-03-05 22:20:48 +0200 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2026-03-05 22:20:48 +0200 |
| commit | 80de1ea2e76ed1283d95b85d808b13ae4338015a (patch) | |
| tree | 7c24eb61f7782f09c9082718f49ad87c556dda81 /internal/tui/entries_test.go | |
| parent | 83ae6b0b19a1f5bb18069210700fc81d2f43278a (diff) | |
add page scrolling keys and bump version to v0.7.0v0.7.0
Diffstat (limited to 'internal/tui/entries_test.go')
| -rw-r--r-- | internal/tui/entries_test.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/internal/tui/entries_test.go b/internal/tui/entries_test.go index 8d6bf1f..baebf56 100644 --- a/internal/tui/entries_test.go +++ b/internal/tui/entries_test.go @@ -140,6 +140,18 @@ func TestEntriesNavigationKeys(t *testing.T) { if model.cursor >= before { t.Fatalf("cursor after ctrl+u = %d, want less than %d", model.cursor, before) } + + model.cursor = 0 + model.offset = 0 + model, _ = model.Update(keyCode(tea.KeyPgDown)) + if got, want := model.cursor, model.pageSize(); got != want { + t.Fatalf("cursor after pgdown = %d, want %d", got, want) + } + + model, _ = model.Update(keyCode(tea.KeyPgUp)) + if model.cursor != 0 { + t.Fatalf("cursor after pgup = %d, want 0", model.cursor) + } } func TestEntriesSearchAndFilter(t *testing.T) { |
