build(deps): bump pytest-cov from 5.0.0 to 6.0.0 (#751) #351
This file contains 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: Stage | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- dev | |
jobs: | |
stage: | |
runs-on: ubuntu-latest | |
environment: staging | |
name: Build and publish early access to GitHub | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v3 | |
- name: Setup Python 3.10 | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.10' | |
- name: Cache pip repository | |
uses: actions/cache@v4 | |
with: | |
path: ~/.cache/pip | |
key: ${{ runner.os }}-pip-${{ hashFiles('requirements.txt', 'requirements_test.txt') }} | |
- name: Prepare python environment | |
run: | | |
pip install --upgrade pip | |
pip install -r requirements.txt -r requirements_test.txt | |
- name: Test project | |
run: pytest -v --cov --cov-report=xml:coverage.xml | |
- name: Cache Docker layers | |
uses: actions/cache@v4 | |
with: | |
path: /tmp/.buildx-cache | |
key: ${{ runner.os }}-buildx-${{ hashFiles('**/Dockerfile') }} | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3.2.0 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3.7.1 | |
- name: Login to GHCR | |
uses: docker/login-action@v3.3.0 | |
with: | |
registry: ghcr.io | |
username: ${{ github.repository_owner }} | |
password: ${{ secrets.GHCR_PAT }} | |
- name: Get current date | |
id: getDate | |
run: echo "date=$(date +'%Y-%m-%d')" >> $GITHUB_OUTPUT | |
- name: Build images and push to GHCR | |
uses: docker/build-push-action@v6.9.0 | |
with: | |
context: . | |
push: true | |
platforms: linux/amd64,linux/arm/v7,linux/arm64/v8 | |
tags: ghcr.io/tomerfi/switcher_webapi:early-access | |
build-args: | | |
VCS_REF=${{ github.sha }} | |
BUILD_DATE=${{ steps.getDate.outputs.date }} | |
VERSION=early-access | |
cache-from: | | |
type=local,src=/tmp/.buildx-cache | |
ghcr.io/tomerfi/switcher_webapi:early-access | |
cache-to: type=local,dest=/tmp/.buildx-cache | |
- name: Push coverage report to CodeCov | |
uses: codecov/codecov-action@v4 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
files: coverage.xml | |
fail_ci_if_error: true |