diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5166977..d0a2b3f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -5,4 +5,4 @@ pytest: # - python -m venv .venv # - source /bin/activate - pip install -r requirements.txt - - pytest \ No newline at end of file + - pytest --disable-warnings \ No newline at end of file diff --git a/requirements.txt b/requirements.txt index ee1a593..bf7666b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -23,3 +23,4 @@ ujson==5.8.0 virtualenv==20.24.6 waitress==2.1.2 Werkzeug==3.0.1 +pycodestyle==2.11.1 \ No newline at end of file diff --git a/tests/general/test_pep8.py b/tests/general/test_pep8.py new file mode 100644 index 0000000..495618c --- /dev/null +++ b/tests/general/test_pep8.py @@ -0,0 +1,9 @@ +import pycodestyle + +# Tests files to ensure they conform to pep8 standards +def test_pep8_conformance(): + """Test that we conform to PEP8.""" + pep8style = pycodestyle.StyleGuide() + dirs = ["./controllers", "./models", "./scripts", "./tests"] + result = pep8style.check_files(dirs) + assert result.total_errors == 0 \ No newline at end of file