refact: code de-nesting #58
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Unit Tests | |
| permissions: | |
| contents: read | |
| on: | |
| pull_request: | |
| types: [ reopened ] | |
| push: | |
| env: | |
| PY_BASE_VERSION: "3.10" | |
| jobs: | |
| coverage-test: # Tests code for base version and coverage | |
| runs-on: windows-latest | |
| steps: | |
| - &checkout | |
| uses: rsb-23/actions/checkout@main | |
| - uses: &test-runner ./.github/test-runner | |
| with: | |
| python-version: ${{ env.PY_BASE_VERSION }} | |
| coverage: true | |
| - name: Upload coverage report | |
| if: always() | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: coverage-report | |
| path: coverage.xml | |
| macos-test: # Tests on macOS latest | |
| needs: coverage-test | |
| runs-on: macos-latest | |
| steps: | |
| - *checkout | |
| - uses: *test-runner | |
| with: | |
| python-version: ${{ env.PY_BASE_VERSION }} | |
| version-tests: # Tests code for higher version in ubuntu | |
| needs: coverage-test | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| python-version: [ "3.11", "3.12", "3.13", "3.14" ] | |
| steps: | |
| - *checkout | |
| - uses: *test-runner | |
| with: | |
| python-version: ${{ matrix.python-version }} |