Cura/.github/workflows/unit-test.yml
Jelle Spijker e688a3a9df
use relative location of pytest
Somehow pytest can't be found on the PATH

Contributes to CURA-10831
2023-12-05 05:51:48 +01:00

61 lines
1.5 KiB
YAML

name: unit-test
on:
push:
paths:
- 'plugins/**'
- 'resources/**'
- 'cura/**'
- 'icons/**'
- 'tests/**'
- '.github/workflows/unit-test.yml'
- '.github/workflows/requirements-runner.txt'
- 'requirements*.txt'
- 'conanfile.py'
- 'conandata.yml'
- '*.jinja'
branches:
- main
- 'CURA-*'
- 'PP-*'
- '[0-9]+.[0-9]+'
pull_request:
paths:
- 'plugins/**'
- 'resources/**'
- 'cura/**'
- 'icons/**'
- 'tests/**'
- '.github/workflows/unit-test.yml'
- '.github/workflows/requirements-runner.txt'
- 'requirements*.txt'
- 'conanfile.py'
- 'conandata.yml'
- '*.jinja'
branches:
- main
- '[0-9]+.[0-9]+'
permissions:
contents: read
env:
CONAN_LOGIN_USERNAME: ${{ secrets.CONAN_USER }}
CONAN_PASSWORD: ${{ secrets.CONAN_PASS }}
jobs:
conan-recipe-version:
uses: ultimaker/cura-workflows/.github/workflows/conan-recipe-version.yml@CURA-10831
with:
project_name: cura
testing:
uses: ultimaker/cura-workflows/.github/workflows/unit-test.yml@CURA-10831
needs: [ conan-recipe-version ]
with:
recipe_id_full: ${{ needs.conan-recipe-version.outputs.recipe_id_full }}
conan_extra_args: '-o cura:devtools=True -c tools.build:skip_test=False'
unit_test_cmd: '../venv/bin/pytest --junitxml=junit_cura.xml'
unit_test_dir: 'tests'
conan_generator_dir: './venv/bin'