Skip to content

Commit 9d44053

Browse files
committed
Improve codestyle check
Signed-off-by: Philippe Ombredanne <pombredanne@nexb.com>
1 parent 1a01ec3 commit 9d44053

1 file changed

Lines changed: 7 additions & 3 deletions

File tree

tests/test_codestyle.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,15 @@
1010

1111
class BaseTests(unittest.TestCase):
1212
def test_codestyle(self):
13-
args = "python -m black --check -l 100 *.py etc/ src/ tests/ docs"
13+
args = "venv/bin/black --check -l 100 setup.py etc src tests docs"
1414
try:
1515
subprocess.check_output(args.split())
16-
except Exception as e:
16+
except subprocess.CalledProcessError as e:
17+
print("===========================================================")
18+
print(e.output)
19+
print("===========================================================")
1720
raise Exception(
1821
"Black style check failed; please format the code using:\n"
19-
" python -m black -l 100 *.py etc/ src/ tests/ docs"
22+
" python -m black -l 100 setup.py etc src tests docs",
23+
e.output,
2024
) from e

0 commit comments

Comments
 (0)