Refactor python/tidy.py to not use globals. Fixes #3242

This commit is contained in:
Duncan Keall 2014-09-09 11:49:35 +12:00
parent 523270c265
commit 6c48066565
2 changed files with 65 additions and 66 deletions

View file

@ -105,11 +105,7 @@ class MachCommands(CommandBase):
description='Run the source code tidiness check',
category='testing')
def test_tidy(self):
errors = 0
for p in ["src", "components"]:
ret = tidy.scan(path.join(self.context.topdir, p))
if ret != 0: errors = 1
return errors
return tidy.scan()
@Command('test-wpt',
description='Run the web platform tests',