File tree Expand file tree Collapse file tree 4 files changed +27
-9
lines changed
Expand file tree Collapse file tree 4 files changed +27
-9
lines changed Original file line number Diff line number Diff line change 11# Changes here will be overwritten by Copier
2- _commit : f8b63c7
2+ _commit : 33cc159
33_src_path : https://github.com/python-project-templates/base.git
44add_extension : rust
55email : 3105306+timkpaine@users.noreply.github.com
Original file line number Diff line number Diff line change 7777
7878 - name : Checks
7979 run : make checks
80- if : ${{ matrix.os == 'ubuntu-latest' }}
80+ if : matrix.os == 'ubuntu-latest'
8181
8282 - name : Build
8383 run : make build
@@ -88,33 +88,36 @@ jobs:
8888 - name : Upload test results (Python)
8989 uses : actions/upload-artifact@v4
9090 with :
91- name : pytest-results-${{ matrix.os }}-${{ matrix.python-version }}
92- path : junit.xml
91+ name : test-results-${{ matrix.os }}-${{ matrix.python-version }}
92+ path : |
93+ **/junit.xml
9394 if : ${{ always() }}
9495
9596 - name : Publish Unit Test Results
9697 uses : EnricoMi/publish-unit-test-result-action@v2
9798 with :
9899 files : |
99100 **/junit.xml
100- if : ${{ matrix.os == 'ubuntu-latest' }}
101+ if : matrix.os == 'ubuntu-latest'
101102
102103 - name : Upload coverage
103104 uses : codecov/codecov-action@v4
105+ with :
106+ token : ${{ secrets.CODECOV_TOKEN }}
104107
105108 - name : Make dist
106109 run : |
107110 make dist-rust
108111 make dist-py-sdist
109112 make dist-py-wheel
110113 make dist-check
111- if : ${{ matrix.os == 'ubuntu-latest' }}
114+ if : matrix.os == 'ubuntu-latest'
112115
113116 - name : Make dist
114117 run : |
115118 make dist-py-wheel
116119 make dist-check
117- if : ${{ matrix.os != 'ubuntu-latest' }}
120+ if : matrix.os != 'ubuntu-latest'
118121
119122 - uses : actions/upload-artifact@v4
120123 with :
Original file line number Diff line number Diff line change @@ -83,13 +83,13 @@ annotate: ## run python type annotation checks with mypy
8383# ########
8484.PHONY : test-py tests-py coverage-py
8585test-py : # # run python tests
86- python -m pytest -v rust_template/tests --junitxml=junit.xml
86+ python -m pytest -v rust_template/tests
8787
8888# alias
8989tests-py : test-py
9090
9191coverage-py : # # run python tests and collect test coverage
92- 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
92+ python -m pytest -v rust_template/tests --cov=rust_template --cov-report term-missing --cov-report xml
9393
9494.PHONY : test-rust tests-rust coverage-rust
9595test-rust : # # run rust tests
Original file line number Diff line number Diff line change @@ -100,7 +100,22 @@ archs = "x86_64 arm64"
100100environment = {PATH =" $UserProfile\\ .cargo\b in;$PATH" }
101101archs = " AMD64 x86"
102102
103+ [tool .coverage .run ]
104+ branch = true
105+ omit = [
106+ " rust_template/tests/integration/" ,
107+ ]
108+ [tool .coverage .report ]
109+ exclude_also = [
110+ " raise NotImplementedError" ,
111+ " if __name__ == .__main__.:" ,
112+ " @(abc\\ .)?abstractmethod" ,
113+ ]
114+ ignore_errors = true
115+ fail_under = 50
116+
103117[tool .pytest .ini_options ]
118+ addopts = [" -vvv" , " --junitxml=junit.xml" ]
104119asyncio_mode = " strict"
105120testpaths = " rust_template/tests"
106121
You can’t perform that action at this time.
0 commit comments