Skip to content

Commit

Permalink
Delete testing part from Docs workflow and only build docs with Pytho…
Browse files Browse the repository at this point in the history
…n 3.9
  • Loading branch information
seisman committed Mar 10, 2021
1 parent 2b1cfbd commit 4adf973
Showing 1 changed file with 4 additions and 31 deletions.
35 changes: 4 additions & 31 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# This workflow installs PyGMT dependencies, build documentation and run tests
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
# This workflow installs PyGMT, build and deploy documentation

name: Tests
name: Docs

on:
push:
Expand All @@ -22,13 +21,13 @@ on:
- cron: '0 0 * * *'

jobs:
test:
docs:
name: ${{ matrix.os }} - Python ${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
python-version: [3.7, 3.8, 3.9]
python-version: [3.9]
os: [ubuntu-latest, macOS-latest, windows-latest]
# Is it a draft Pull Request (true or false)?
isDraft:
Expand All @@ -46,11 +45,6 @@ jobs:
python-version: 3.8
isDraft: true

# environmental variables used in coverage
env:
OS: ${{ matrix.os }}
PYTHON: ${{ matrix.python-version }}

steps:
# Cancel previous runs that are not completed
- name: Cancel Previous Runs
Expand Down Expand Up @@ -110,32 +104,11 @@ jobs:
python setup.py sdist --formats=zip
pip install dist/*
# Run the tests
- name: Test with pytest
shell: bash -l {0}
run: make test PYTEST_EXTRA="-r P"

# Upload diff images on test failure
- name: Upload diff images if any test fails
uses: actions/upload-artifact@v2
if: ${{ failure() }}
with:
name: artifact-${{ runner.os }}-${{ matrix.python-version }}
path: tmp-test-dir-with-unique-name

# Build the documentation
- name: Build the documentation
shell: bash -l {0}
run: make -C doc clean all

# Upload coverage to Codecov
- name: Upload coverage to Codecov
uses: codecov/[email protected]
with:
file: ./coverage.xml # optional
env_vars: OS,PYTHON
fail_ci_if_error: false

- name: Checkout the gh-pages branch
uses: actions/checkout@28c7f3d2b5162b5ddd3dfd9a45aa55eaf396478b
with:
Expand Down

0 comments on commit 4adf973

Please sign in to comment.