예제 #1
0
def test_get_matches_no_match(movies):
    releases = ['Game.of.Thrones.S03E10.HDTV.EVOLVE']
    subtitle = SubsCenterSubtitle(Language('heb'), False, None,
                                  'Game of Thrones', 3, 10, 'Mhysa', 263129,
                                  '6a3129e8b9effdb8231aa6b3caf66fbe', 6706,
                                  releases)
    matches = subtitle.get_matches(movies['man_of_steel'])
    assert matches == set()
예제 #2
0
def test_get_matches_movie(movies):
    releases = ['Enders.Game.2013.HC.Webrip.x264.AC3-TiTAN', 'Enders.Game.2013.KORSUB.HDRip.XViD-NO1KNOWS',
                'Enders.Game.2013.KORSUB.HDRip.h264.AAC-RARBG', 'Enders.Game.2013.HDRip.XViD.AC3-ReLeNTLesS',
                'Enders.Game.2013.720p.KOR.HDRip.H264-KTH']
    subtitle = SubsCenterSubtitle(Language('heb'), False, None, None, None, None, 'Ender\'s Game', 266898,
                                  '54adce017db2e7fd8501b7a321451b64', 389, releases)
    matches = subtitle.get_matches(movies['enders_game'])
    assert matches == {'title', 'year', 'resolution', 'video_codec', 'hearing_impaired'}
예제 #3
0
def test_get_matches_episode(episodes):
    releases = ['Game.of.Thrones.S03E10.HDTV.x264-EVOLVE']
    subtitle = SubsCenterSubtitle(Language('heb'), False, None,
                                  'Game of Thrones', 3, 10, 'Mhysa', 263129,
                                  '6a3129e8b9effdb8231aa6b3caf66fbe', 6706,
                                  releases)
    matches = subtitle.get_matches(episodes['got_s03e10'])
    assert matches == {
        'series', 'episode', 'season', 'title', 'year', 'video_codec'
    }
예제 #4
0
def test_get_matches_no_match(movies):
    releases = ['Game.of.Thrones.S03E10.HDTV.EVOLVE']
    subtitle = SubsCenterSubtitle(Language('heb'), False, None, 'Game of Thrones', 3, 10, 'Mhysa', 263129,
                                  '6a3129e8b9effdb8231aa6b3caf66fbe', 6706, releases)
    matches = subtitle.get_matches(movies['man_of_steel'], hearing_impaired=True)
    assert matches == set()
예제 #5
0
def test_get_matches_episode(episodes):
    releases = ['Game.of.Thrones.S03E10.HDTV.x264-EVOLVE']
    subtitle = SubsCenterSubtitle(Language('heb'), False, None, 'Game of Thrones', 3, 10, 'Mhysa', 263129,
                                  '6a3129e8b9effdb8231aa6b3caf66fbe', 6706, releases)
    matches = subtitle.get_matches(episodes['got_s03e10'])
    assert matches == {'series', 'episode', 'season', 'title', 'year', 'video_codec', 'hearing_impaired'}