diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index eeff0d3..7a9f38a 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -44,7 +44,6 @@ jobs: - name: Set up miniconda uses: conda-incubator/setup-miniconda@v3 with: - miniforge-variant: Miniforge miniforge-version: latest channels: conda-forge,bioconda activate-environment: prymer @@ -54,38 +53,16 @@ jobs: auto-activate-base: false python-version: ${{ matrix.PYTHON_VERSION }} - - name: Unit tests (with doctest and coverage) - shell: bash -l {0} - run: | - conda activate prymer - poetry run pytest --cov=prymer --cov-report=xml --cov-branch --doctest-plus --doctest-modules prymer tests + - name: Install the project's dependencies + run: poetry install + + - name: Test the codebase + run: poetry run pytest - name: Upload coverage reports to Codecov uses: codecov/codecov-action@v4.5.0 with: token: ${{ secrets.CODECOV_TOKEN }} - - - name: Style checking - shell: bash -l {0} - run: | - conda activate prymer - poetry run ruff format --check - - - name: Run lint - shell: bash -l {0} - run: | - conda activate prymer - poetry run ruff check - - - name: Run mypy - shell: bash -l {0} - run: | - conda activate prymer - poetry run mypy - - name: Run docs - shell: bash -l {0} - run: | - conda activate prymer - set -euo pipefail - poetry run mkdocs build --strict + - name: Test building the documentation + run: set -euo pipefail && poetry run mkdocs build --strict diff --git a/pyproject.toml b/pyproject.toml index 4ccb6cb..e4a2898 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -125,6 +125,11 @@ minversion = "7.4" addopts = [ "--ignore=docs/scripts", "--color=yes", + "--cov", + "--cov-report=xml", + "--cov-branch", + "--doctest-plus", + "--doctest-modules", "--mypy", "--ruff", "--doctest-plus",