django_example_ynh/tests/test_lint.py

14 lines
297 B
Python
Raw Normal View History

2020-12-28 20:14:57 +01:00
import shutil
import subprocess
from pathlib import Path
BASE_PATH = Path(__file__).parent.parent
2020-12-28 20:14:57 +01:00
def test_lint():
assert Path(BASE_PATH, 'Makefile').is_file()
make_bin = shutil.which('make')
assert make_bin is not None
subprocess.check_call([make_bin, 'lint'], cwd=BASE_PATH)