diff --git a/.github/workflows/python_actions.yml b/.github/workflows/python_actions.yml index 86108df..f1f9717 100644 --- a/.github/workflows/python_actions.yml +++ b/.github/workflows/python_actions.yml @@ -72,3 +72,15 @@ jobs: - name: Test with nbmake run: bash integration_tests/pytest.bash + + - name: Lint with flake8 + run: flake8 integration_tests spinnaker_jupyter_examples + + - name: Lint with pylint + uses: ./support/actions/pylint + with: + package: ${{ env.BASE_PKG }} + exitcheck: 31 # Action fails on any message + language: en_GB + + diff --git a/.gitignore b/.gitignore index 04f52ac..a88d0d0 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,4 @@ /.pydevproject .ipynb_checkpoints .pytest_cache -.pytest.bash \ No newline at end of file +.pytest.bash diff --git a/integration_tests/bash_builder.py b/integration_tests/bash_builder.py index 1e4c0b7..fc1e16e 100644 --- a/integration_tests/bash_builder.py +++ b/integration_tests/bash_builder.py @@ -25,6 +25,8 @@ class BashBuilder(object): def add_scripts(self, a_dir, prefix_len, test_file, exceptions): """ + Adds a test(s) for a single file or to all in a directory + :param str a_dir: :param int prefix_len: :param io.TextIOBase test_file: @@ -49,6 +51,11 @@ def add_scripts(self, a_dir, prefix_len, test_file, exceptions): test_file.write("\n") def build_bash(self, exceptions): + """ + Creates a bash file to run nbmake on all notebooks + + :param exceptions: List of notebooks not to include + """ class_file = sys.modules[self.__module__].__file__ # Ned this for python 3.8 class_file = os.path.abspath(class_file)