diff --git a/.copier-answers.yml b/.copier-answers.yml index e0ca392..c68b45a 100644 --- a/.copier-answers.yml +++ b/.copier-answers.yml @@ -1,5 +1,5 @@ # Changes here will be overwritten by Copier -_commit: f8b63c7 +_commit: 33cc159 _src_path: https://github.com/python-project-templates/base.git add_extension: rust email: 3105306+timkpaine@users.noreply.github.com diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e6d2247..c786e8e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -77,7 +77,7 @@ jobs: - name: Checks run: make checks - if: ${{ matrix.os == 'ubuntu-latest' }} + if: matrix.os == 'ubuntu-latest' - name: Build run: make build @@ -88,8 +88,9 @@ jobs: - name: Upload test results (Python) uses: actions/upload-artifact@v4 with: - name: pytest-results-${{ matrix.os }}-${{ matrix.python-version }} - path: junit.xml + name: test-results-${{ matrix.os }}-${{ matrix.python-version }} + path: | + **/junit.xml if: ${{ always() }} - name: Publish Unit Test Results @@ -97,10 +98,12 @@ jobs: with: files: | **/junit.xml - if: ${{ matrix.os == 'ubuntu-latest' }} + if: matrix.os == 'ubuntu-latest' - name: Upload coverage uses: codecov/codecov-action@v4 + with: + token: ${{ secrets.CODECOV_TOKEN }} - name: Make dist run: | @@ -108,13 +111,21 @@ jobs: make dist-py-sdist make dist-py-wheel make dist-check +<<<<<<< before updating if: ${{ matrix.os == 'ubuntu-latest' }} +======= + if: matrix.os == 'ubuntu-latest' +>>>>>>> after updating - name: Make dist run: | make dist-py-wheel make dist-check +<<<<<<< before updating if: ${{ matrix.os != 'ubuntu-latest' }} +======= + if: matrix.os != 'ubuntu-latest' +>>>>>>> after updating - uses: actions/upload-artifact@v4 with: diff --git a/Makefile b/Makefile index 044ba02..0e96553 100644 --- a/Makefile +++ b/Makefile @@ -83,13 +83,17 @@ annotate: ## run python type annotation checks with mypy ######### .PHONY: test-py tests-py coverage-py test-py: ## run python tests +<<<<<<< before updating python -m pytest -v rust_template/tests --junitxml=junit.xml +======= + python -m pytest -v rust_template/tests +>>>>>>> after updating # alias tests-py: test-py coverage-py: ## run python tests and collect test coverage - python -m pytest -v rust_template/tests --junitxml=junit.xml --cov=rust_template --cov-branch --cov-fail-under=50 --cov-report term-missing --cov-report xml + python -m pytest -v rust_template/tests --cov=rust_template --cov-report term-missing --cov-report xml .PHONY: test-rust tests-rust coverage-rust test-rust: ## run rust tests diff --git a/pyproject.toml b/pyproject.toml index 70edb40..2809163 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -100,7 +100,25 @@ archs = "x86_64 arm64" environment = {PATH="$UserProfile\\.cargo\bin;$PATH"} archs = "AMD64 x86" +<<<<<<< before updating +======= +[tool.coverage.run] +branch = true +omit = [ + "rust_template/tests/integration/", +] +[tool.coverage.report] +exclude_also = [ + "raise NotImplementedError", + "if __name__ == .__main__.:", + "@(abc\\.)?abstractmethod", +] +ignore_errors = true +fail_under = 50 + +>>>>>>> after updating [tool.pytest.ini_options] +addopts = ["-vvv", "--junitxml=junit.xml"] asyncio_mode = "strict" testpaths = "rust_template/tests"