Scroll the guide a row early and show which channels are in view (0.53.0)
pauljd/davidson-ci: Davidson CI / quality (push) Failing after 1m38s
pauljd/davidson-ci: Davidson CI / ai-review (push) Failing after 1m28s

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-11-02 09:26:13 +00:00
co-authored by Claude Opus 5.5
parent 11500dfae6
commit 4585aa018b
5 changed files with 21 additions and 10 deletions
@@ -86,9 +86,9 @@ class GuideGridTest {
@Test
fun theGridScrollsOnlyWhenTheChosenRowLeavesTheScreen() {
assertEquals(0, guideFirstRow(3, 0, 8, 25))
assertEquals(1, guideFirstRow(8, 0, 8, 25))
assertEquals(2, guideFirstRow(8, 0, 8, 25))
assertEquals(5, guideFirstRow(9, 5, 8, 25))
assertEquals(4, guideFirstRow(4, 5, 8, 25))
assertEquals(3, guideFirstRow(4, 5, 8, 25))
assertEquals(17, guideFirstRow(24, 10, 8, 25))
}
@@ -97,4 +97,12 @@ class GuideGridTest {
assertEquals(0, guideFirstRow(2, 0, 8, 3))
assertEquals(0, guideFirstRow(0, 4, 8, 3))
}
@Test
fun theNextChannelIsAlwaysInSight() {
assertEquals(1, guideFirstRow(1, 2, 6, 11))
assertEquals(0, guideFirstRow(0, 1, 6, 11))
assertEquals(1, guideFirstRow(5, 0, 6, 11))
assertEquals(5, guideFirstRow(10, 0, 6, 11))
}
}