Avoid deprecation warning from pytest-asyncio #17631
Workflow file for this run
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: Python doctest | |
on: | |
push: | |
branches: | |
- main | |
- 'version-**' | |
tags: "*" | |
pull_request: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
jobs: | |
python-doctest: | |
name: Set up Python | |
timeout-minutes: 40 | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
id: setup_python | |
with: | |
python-version: '3.11' | |
cache: "pip" | |
cache-dependency-path: | | |
pyproject.toml | |
- run: pip install -e ".[dev]" | |
- name: Test doctest | |
run: | | |
# dark storage assumes it is a started service so cannot be excluded | |
# by pytest blindly | |
pytest --doctest-modules --cov=ert --cov-report=xml:cov.xml src/ --ignore src/ert/dark_storage | |
- name: Upload coverage to Codecov | |
id: codecov1 | |
uses: codecov/codecov-action@v4 | |
continue-on-error: true | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
fail_ci_if_error: true | |
files: cov.xml | |
- name: codecov retry sleep | |
if: steps.codecov1.outcome == 'failure' | |
run: | | |
sleep 30 | |
- name: Codecov retry | |
uses: codecov/codecov-action@v4 | |
if: steps.codecov1.outcome == 'failure' | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
files: cov.xml | |
fail_ci_if_error: ${{ github.ref == 'refs/heads/main' }} |