Add the last 11 channels to complete the lineup (0.66.0)
pauljd/davidson-ci: Davidson CI / quality (push) Failing after 2m31s
pauljd/davidson-ci: Davidson CI / ai-review (push) Failing after 2m50s

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-11-02 11:38:34 +00:00
co-authored by Claude Opus 5.5
parent 5257ffdad8
commit aa2830fa4b
30 changed files with 81 additions and 6 deletions
@@ -155,4 +155,27 @@ class ChannelPresetsTest {
assertEquals(listOf("Movie", "Movie"), loop.lineup.map { it.item.type })
assertEquals("Film a", loop.lineup.first().item.title)
}
@Test fun theLastChannelsAreConfiguredAndBranded() {
listOf(104, 126, 127, 131, 132, 133, 134, 135, 136, 144, 150).forEach { number ->
assertNotNull(ChannelBrands.forNumber(number))
assertTrue(SmartChannels.any { it.number == number && it.exactTitles })
}
listOf(126, 127, 131, 132, 133, 134, 135, 136).forEach { assertNotNull(SmartChannels.first { channel -> channel.number == it }.filmRestMs) }
assertEquals(ChannelCategory.Sport, ChannelBrands.forNumber(150)!!.category)
assertEquals(28, SmartChannels.size)
}
@Test fun ringXKeepsItsWeeknightsAndFallsBackToTheVault() {
val ringX = SmartChannels.first { it.number == 150 }
val london = java.time.ZoneId.of("Europe/London")
fun show(title: String) = PoolSeries(title, title, listOf(PoolEpisode("$title-1", "s", EpisodeMark(1, 1), "E1", 60_000)))
val pool = listOf(show("WCW Monday Nitro"), show("AEW Dynamite"), show("WrestleMania"))
fun on(day: Int) = java.time.ZonedDateTime.of(2026, 11, day, 21, 0, 0, 0, london).toInstant().toEpochMilli()
assertEquals(listOf("WCW Monday Nitro"), dayPartPool(pool, ringX.dayParts, on(2), london).map { it.title })
assertEquals(listOf("AEW Dynamite"), dayPartPool(pool, ringX.dayParts, on(4), london).map { it.title })
assertEquals(3, dayPartPool(pool, ringX.dayParts, on(7), london).size)
// No Impact in this library, so Tuesday isn't left empty.
assertEquals(3, dayPartPool(pool, ringX.dayParts, on(3), london).size)
}
}