Private GIT

Skip to content
Snippets Groups Projects
Commit 60c03996 authored by echel0n's avatar echel0n
Browse files

Fix name parser issues for unitests

parent d96597bf
Branches
Tags
No related merge requests found
......@@ -162,7 +162,12 @@ class UnicodeTests(test.SickbeardTestDBCase):
def _test_unicode(self, name, result):
np = parser.NameParser(True)
try:
parse_result = np.parse(name)
except parser.InvalidShowException:
return False
# this shouldn't raise an exception
a = repr(str(parse_result))
......@@ -176,7 +181,7 @@ class FailureCaseTests(test.SickbeardTestDBCase):
np = parser.NameParser(True)
try:
parse_result = np.parse(name)
except parser.InvalidNameException:
except (parser.InvalidNameException, parser.InvalidShowException):
return True
if VERBOSE:
......@@ -196,7 +201,11 @@ class ComboTests(test.SickbeardTestDBCase):
print 'Testing', name
np = parser.NameParser(True)
try:
test_result = np.parse(name)
except parser.InvalidShowException:
return False
if DEBUG:
print test_result, test_result.which_regex
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment