Commit a3ee2635 authored by FichteFoll's avatar FichteFoll

tests: indent line number output +1 and PEP8

parent 88679bf3
......@@ -169,7 +169,7 @@ class TestContainer(object):
def _test_repository_indents(self, include, contents):
for i, line in enumerate(contents.splitlines()):
self.assertRegex(line, r"^\t*\S",
"Indent must be tabs in line %d" % i)
"Indent must be tabs in line %d" % (i + 1))
def _test_package(self, include, data):
for k, v in data.items():
......@@ -307,7 +307,7 @@ class ChannelTests(TestContainer, unittest.TestCase):
try:
data = json.loads(source)
except Exception as e:
yield cls._fail("Could not parse %s" % repository ,e)
yield cls._fail("Could not parse %s" % repository, e)
continue
# Check for the schema version first (and generator failures it's
......@@ -339,6 +339,8 @@ class ChannelTests(TestContainer, unittest.TestCase):
("%s (%s)" % (package_name, repository),
release, False))
# TODO: test includes
@generator_class
class RepositoryTests(TestContainer, unittest.TestCase):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment