feat: Use Pixi, pyradiomics fork #254
Workflow file for this run
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: CI-CD | |
# only run on pushes to main or pull requests | |
on: | |
push: | |
# push to any branch * | |
branches: ["*"] | |
pull_request: | |
branches: [main, development] | |
jobs: | |
################################################################################################ | |
# Unit-Tests: Run unit tests using pytest | |
################################################################################################ | |
Unit-Tests: | |
runs-on: ${{ matrix.os }} | |
timeout-minutes: 15 # Consider increasing timeout | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest, macos-14] # , windows-latest removed for now | |
env: ["py310", "py311", "py312"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Pixi | |
uses: prefix-dev/setup-pixi@v0.8.1 | |
with: | |
environments: ${{ matrix.env }} | |
pixi-version: v0.33.0 | |
cache: true | |
locked: false # wont be the same because of the tag | |
- name: Run pytest | |
run: | | |
pixi run -e ${{ matrix.env }} test | |
- name: Upload coverage report artifact to be used by Codecov | |
# only upload if matrix.os is ubuntu-latest and matrix.python-version is 3.12 | |
if: matrix.os == 'ubuntu-latest' && matrix.env == 'py312' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: coverage-report | |
path: coverage-report | |
################################################################################################ | |
# Publish-To-PyPi & Test-PyPi-Installation: Publish to PyPI and test installation | |
################################################################################################ | |
# Publish-To-PyPi: | |
# needs: Semantic-Release | |
# env: | |
# PIXI_ENV: "publish" | |
# # if: needs.Semantic-Release.outputs.released == 'true' | |
# strategy: | |
# matrix: | |
# os: [ubuntu-latest] | |
# runs-on: ${{ matrix.os }} | |
# steps: | |
# - name: Checkout the code with tag ${{ needs.Semantic-Release.outputs.tag }} | |
# uses: actions/checkout@v4 | |
# with: | |
# ref: ${{ needs.Semantic-Release.outputs.tag }} | |
# - name: Install Pixi | |
# uses: prefix-dev/setup-pixi@v0.8.1 | |
# with: | |
# environments: ${{ env.PIXI_ENV }} | |
# pixi-version: v0.33.0 | |
# # cache-key: pixi-ENV_${{ env.PIXI_ENV }}- | |
# cache: true | |
# locked: false # wont be the same because of the tag | |
# - name: Test Build | |
# run: | | |
# pixi run -e ${{ env.PIXI_ENV }} build |