From 10694a83d14894cb36eb92b9b285d09e1a81bafb Mon Sep 17 00:00:00 2001 From: Adam Cribbs Date: Wed, 19 Apr 2023 10:12:02 +0100 Subject: [PATCH] Update python-package.yml --- .github/workflows/python-package.yml | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/.github/workflows/python-package.yml b/.github/workflows/python-package.yml index ceedf3e..03c1e29 100644 --- a/.github/workflows/python-package.yml +++ b/.github/workflows/python-package.yml @@ -18,17 +18,16 @@ jobs: matrix: python-version: ["3.8", "3.9", "3.10"] + steps: - - uses: actions/checkout@v3 - - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v3 + - name: Checkout code + uses: actions/checkout@v2 + + - name: Set up Conda environment + uses: conda-incubator/setup-miniconda@v2 with: - python-version: ${{ matrix.python-version }} - - name: Install dependencies - run: | - python -m pip install --upgrade pip - python -m pip install flake8 pytest - if [ -f requirements.txt ]; then pip install -r requirements.txt; fi + activate-environment: myenv + environment-file: conda/environment.yml - name: Lint with flake8 run: | # stop the build if there are Python syntax errors or undefined names @@ -38,7 +37,6 @@ jobs: - name: Test with pytest run: | python setup.py install - pycodestyle --ignore=E501 tests - nosetests -v tests/test_import.py - nosetests -v tests/test_style.py - nosetests -v tests/test_pipeline_control.py + pytest -v tests/test_import.py + pytest -v tests/test_style.py + pytest -v tests/test_pipeline_control.py