BLD: update RTD setup file wrt coming deprecations #47
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: Tests | |
on: | |
push: | |
branches: [main, "*postfix"] | |
pull_request: | |
branches: [main] | |
jobs: | |
fast: | |
strategy: | |
matrix: | |
python-version: ["3.8", "3.9", "3.10", "3.11"] | |
os: [ubuntu-latest] | |
include: | |
- os: macos-latest | |
python-version: 3.8 | |
- os: macos-latest | |
python-version: 3.11 | |
- os: windows-latest | |
python-version: 3.8 | |
- os: windows-latest | |
python-version: 3.11 | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- uses: "./.github/actions/test_setup" | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Run test | |
run: python -m pytest --disable-warnings -x --hypothesis-profile ci-fast | |
hypothesis: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- uses: "./.github/actions/test_setup" | |
with: | |
python-version: 3.9 | |
- name: Run just hypothesis tests with more examples | |
run: python -m pytest --disable-warnings -x -m hypothesis --hypothesis-profile ci --generate-plots | |
big: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- uses: "./.github/actions/test_setup" | |
with: | |
python-version: 3.9 | |
- name: Run just tests marked big | |
run: XTG_BIGTEST=1 python -m pytest --disable-warnings -x -m bigtest --hypothesis-profile ci --generate-plots | |
codecov: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- uses: "./.github/actions/test_setup" | |
with: | |
python-version: 3.9 | |
- name: "Install codecov" | |
run: pip install pytest-cov | |
- name: Generate coverage report | |
run: pytest tests --doctest-modules --generate-plots --disable-warnings --cov=xtgeo --hypothesis-profile ci-fast --cov-report=xml:xtgeocoverage.xml; | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v2 | |
with: | |
files: xtgeocoverage.xml |