mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2024-11-26 03:24:01 +03:00
Implement test for flake8 compliance
This commit is contained in:
parent
f579cf08ac
commit
664c72d291
|
@ -2,6 +2,7 @@
|
|||
|
||||
import os
|
||||
import re
|
||||
import sh
|
||||
|
||||
import pytest
|
||||
from binaryornot.check import is_binary
|
||||
|
@ -77,3 +78,13 @@ def test_enabled_features(cookies, feature_context):
|
|||
paths = build_files_list(str(result.project))
|
||||
assert paths
|
||||
check_paths(paths)
|
||||
|
||||
|
||||
def test_flake8_compliance(cookies):
|
||||
"""generated project should pass flake8"""
|
||||
result = cookies.bake()
|
||||
|
||||
try:
|
||||
sh.flake8(str(result.project))
|
||||
except sh.ErrorReturnCode as e:
|
||||
pytest.fail(e)
|
||||
|
|
Loading…
Reference in New Issue
Block a user