0.99.6: After Dark review applied (38 exact items withdrawn, 5 films moved to Horror), with 0.99.5
pauljd/davidson-ci: Davidson CI / quality (push) Failing after 1m41s
pauljd/davidson-ci: Davidson CI / ai-review (push) Failing after 1m34s

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-11-04 09:31:57 +00:00
co-authored by Claude Opus 5.5
parent 99ed169955
commit d4a67212b7
10 changed files with 239 additions and 9 deletions
@@ -0,0 +1,36 @@
package tv.orbit.classic
import org.junit.Assert.assertEquals
import org.junit.Assert.assertTrue
import org.junit.Test
/** Paul's After Dark review (4 November 2026): exact items withdrawn, five films moved to Horror, nothing else touched. */
class AfterDarkReviewTest {
private val afterDark get() = SmartChannels.first { it.number == AFTER_DARK_NUMBER }
private val horror get() = SmartChannels.first { it.number == 304 }
private val moved = listOf("Bram Stoker's Dracula (1992)", "Interview with the Vampire (1994)", "Red Dragon (2002)", "Sweeney Todd: The Demon Barber of Fleet Street (2007)", "The Devil's Advocate (1997)")
@Test fun thirtyEightExactItemsLeaveAfterDarkAndOnlyThere() {
assertEquals(38, afterDark.withdrawn.size)
assertTrue(afterDark.withdrawn.all { EmbyClient.validId(it) })
assertTrue(SmartChannels.filter { it.number != AFTER_DARK_NUMBER }.all { it.withdrawn.isEmpty() })
// The kept films are untouched: nothing withdrawn is on After Dark's own list.
val film = { id: String, title: String -> PoolSeries(id, title, listOf(PoolEpisode(id, "src", EpisodeMark(1, 1), title, 6_000_000))) }
val pool = listOf(film("5653603", "Koi... Mil Gaya"), film("5660745", "The Shining"), film("1", "Zombieland"), film("2", "Black Swan"), film("3", "Terrorizers"), film("4", "The Outcasts"))
assertEquals(listOf("Zombieland", "Black Swan", "Terrorizers", "The Outcasts"), withoutWithdrawn(pool, afterDark.withdrawn).map { it.title })
assertEquals(pool, withoutWithdrawn(pool, emptySet()))
}
@Test fun fiveFilmsMoveToHorrorByExactTitleAndYear() {
moved.forEach { title ->
assertTrue("Horror lists $title", title in horror.searches)
assertTrue("After Dark doesn't list $title", afterDark.searches.none { seriesKey(FilmIdentity.of(it).title) == seriesKey(FilmIdentity.of(title).title) })
assertTrue(FilmIdentity.of(title).year != null)
}
}
@Test fun onlyAfterDarkAndHorrorReadTheirPoolsAgain() {
assertTrue("#withdrawn:" in afterDark.signature)
assertTrue(SmartChannels.filter { it.number != AFTER_DARK_NUMBER }.none { "#withdrawn:" in it.signature })
}
}
@@ -93,6 +93,6 @@ class PpvSundayTest {
assertTrue(ringX.signature.contains("#films:"))
assertTrue(ringX.signature.contains(PpvSunday.first()))
val afterDark = SmartChannels.first { it.number == AFTER_DARK_NUMBER }
assertTrue(afterDark.signature.endsWith("#series:$LAST_DRIVE_IN"))
assertTrue(afterDark.signature.contains("#series:$LAST_DRIVE_IN#"))
}
}