mirror of
https://github.com/narrrl/proton-stream.git
synced 2026-11-04 00:47:00 +01:00
fix(android,ios): the player names the episode, not its file
The header under the episode's numbering showed `Episode::detail`, which falls back to the file name — `[Judas] Chainsaw Man - S01E01.mkv` on a phone, where the desktop shows `Dog & Chainsaw`. It now shows the provider's name for the episode, else the one the file name gave it, and nothing rather than the file name: the release group's tag is no caption, and it is what a screenshot of the player would carry away.
This commit is contained in:
1 parent
79f0d74e1a
commit
b5ba59b41d
6 files changed
+60
-4
No files matched your search
@@ -171,6 +171,18 @@ final class CommonTests: XCTestCase {
|
||||
XCTAssertEqual(bare.heading(0), "Episode 4")
|
||||
}
|
||||
|
||||
func testThePlayerCaptionsAnEpisodeWithItsNameAndNeverItsFilename() {
|
||||
var named = episode("e")
|
||||
named.providerName = "Dog & Chainsaw"
|
||||
XCTAssertEqual(named.shownName, "Dog & Chainsaw")
|
||||
var bare = episode("e")
|
||||
bare.name = "[Group] Show - S01E01.mkv"
|
||||
bare.detail = bare.name
|
||||
XCTAssertNil(bare.shownName)
|
||||
bare.detail = ""
|
||||
XCTAssertNil(bare.shownName)
|
||||
}
|
||||
|
||||
func testEpisodesAreNumberedBySeasonThenByPlaceInTheList() {
|
||||
var numbered = episode("e", number: 38)
|
||||
numbered.season = 3
|
||||
|
||||
Reference in new issue
Block a user