public void FormatSuccess()
        {
            var ef = new EpisodeFormatter("Big Little Lies - S01E01 - Somebody's Dead WEBDL-1080p");

            Assert.Equal(ef.ShowName(), showName);
            Assert.Equal(ef.EpisodeName(), episodeName);
            Assert.Equal(ef.SeasonNumber(), seasonNumber);
            Assert.Equal(ef.EpisodeNumber(), episodeNumber);
        }
Exemple #2
0
        public async Task <Subtitle> FindSubtitle([FromBody] FindSubtitleDto value)
        {
            var episodeFormatter = new EpisodeFormatter(value.FileName);
            var query            = new GetSubtitleQuery
            {
                EpisodePath   = value.FilePath,
                ShowName      = episodeFormatter.ShowName(),
                SeasonNumber  = episodeFormatter.SeasonNumber(),
                EpisodeNumber = episodeFormatter.EpisodeNumber(),
                EpisodeName   = episodeFormatter.EpisodeName()
            };
            var result = await SubtitleQueryHandler.Execute(query);

            return(result);
        }