Tests: Spaces & TABs

Fix TABs and none-PEP8 spaces in approval test.
Does not yet fix overlong lines for full `flake8` compliance.
This commit is contained in:
Axel Huebl 2018-08-28 16:14:21 +02:00 committed by Martin Hořeňovský
parent 7667a7d89c
commit 90663b2e75

View File

@ -1,6 +1,6 @@
#!/usr/bin/env python #!/usr/bin/env python
from __future__ import print_function from __future__ import print_function
import io import io
import os import os
@ -13,8 +13,8 @@ import scriptCommon
from scriptCommon import catchPath from scriptCommon import catchPath
if os.name == 'nt': if os.name == 'nt':
# Enable console colours on windows # Enable console colours on windows
os.system('') os.system('')
rootPath = os.path.join(catchPath, 'projects/SelfTest/Baselines') rootPath = os.path.join(catchPath, 'projects/SelfTest/Baselines')
@ -98,7 +98,6 @@ def filterLine(line, isCompact):
# go from \ in windows paths to / # go from \ in windows paths to /
line = line.replace('\\', '/') line = line.replace('\\', '/')
# strip source line numbers # strip source line numbers
m = filelocParser.match(line) m = filelocParser.match(line)
if m: if m:
@ -112,7 +111,7 @@ def filterLine(line, isCompact):
if isCompact: if isCompact:
line = line.replace(': FAILED', ': failed') line = line.replace(': FAILED', ': failed')
line = line.replace(': PASSED', ': passed') line = line.replace(': PASSED', ': passed')
# strip Catch version number # strip Catch version number
line = versionParser.sub("<version>", line) line = versionParser.sub("<version>", line)
@ -180,7 +179,7 @@ print("Running approvals against executable:")
print(" " + cmdPath) print(" " + cmdPath)
### Keep default reporters here # ## Keep default reporters here ##
# Standard console reporter # Standard console reporter
approve("console.std", ["~[!nonportable]~[!benchmark]~[approvals]", "--order", "lex", "--rng-seed", "0"]) approve("console.std", ["~[!nonportable]~[!benchmark]~[approvals]", "--order", "lex", "--rng-seed", "0"])
# console reporter, include passes, warn about No Assertions # console reporter, include passes, warn about No Assertions