From fe3fd3c49816d7a8ad44dfa28f5f96ca289fedae Mon Sep 17 00:00:00 2001 From: tligui_y Date: Mon, 7 Jul 2025 13:30:33 +0200 Subject: [PATCH] Add .gitea/workflows/test.yml --- .gitea/workflows/test.yml | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .gitea/workflows/test.yml diff --git a/.gitea/workflows/test.yml b/.gitea/workflows/test.yml new file mode 100644 index 00000000..b8a31a6a --- /dev/null +++ b/.gitea/workflows/test.yml @@ -0,0 +1,37 @@ +name: Run Pytest with Pixi and generate Allure & Coverage + +on: + push: + branches: [ utils_testing ] # Modifie si tu veux cibler une autre branche + pull_request: + +jobs: + tests: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Install Pixi + run: | + curl -fsSL https://pixi.sh/install.sh | bash + export PATH="$HOME/.pixi/bin:$PATH" + pixi install + + - name: Run tests with coverage and allure + run: | + export PATH="$HOME/.pixi/bin:$PATH" + pixi run pytest --cov=slic --cov-report=xml --cov-report=html --alluredir=allure-results + + - name: Upload Allure results + uses: actions/upload-artifact@v4 + with: + name: allure-results + path: allure-results/ + + - name: Upload Coverage HTML report + uses: actions/upload-artifact@v4 + with: + name: coverage-html + path: htmlcov/