def test_title_noepisode(self): show_list = ["Something", "Shit Talkers"] title = "Shit Talkers" expected = None result = tvservice.detect_show(show_list, title) self.assertEqual(result, expected)
def test_title_nomatch(self): show_list = ["Something", "Shit"] title = "Shitake Mushrooms" expected = None result = tvservice.detect_show(show_list, title) self.assertEqual(result, expected)
def test_date_episode(self): show_list = ["Something", "How.I.Met.Your.Father"] title = "How I met your father 2011 12 05" expected = ("How.I.Met.Your.Father", "2011 12 05") result = tvservice.detect_show(show_list, title) self.assertEqual(result, expected)
def test_scunthorpe(self): show_list = ["Something", "Shit"] title = "How to cook Shitake Mushrooms" expected = None result = tvservice.detect_show(show_list, title) self.assertEqual(result, expected)
def test_normalize_name(self): show_list = ["Something", "How.I.Met.Your.Father"] title = "How I met your father S01E02" expected = ("How.I.Met.Your.Father", "S01E02") result = tvservice.detect_show(show_list, title) self.assertEqual(result, expected)