Skip to content

Commit

Permalink
Fix CI (#410)
Browse files Browse the repository at this point in the history
* Fix CI

* Use old docutils
  • Loading branch information
jarrodmillman committed Jun 9, 2022
1 parent a134280 commit a4dd122
Showing 1 changed file with 64 additions and 3 deletions.
67 changes: 64 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,16 @@ jobs:
strategy:
matrix:
os: [Ubuntu]
python-version: ["3.7", "3.8", "3.9", "3.10"]
sphinx-version: ["sphinx==3.0", "sphinx==4.0", "sphinx>4.4"]
python-version: ["3.7", "3.8", "3.9"]
sphinx-version:
[
"sphinx==3.0",
"sphinx==3.5",
"sphinx==4.0",
"sphinx==4.5",
"sphinx==5.0",
"sphinx>=5.0",
]
steps:
- uses: actions/checkout@v3

Expand All @@ -32,7 +40,7 @@ jobs:
- name: Downgrade Jinja2 for sphinx<4
if: ${{ matrix.sphinx-version }} == 'sphinx<4.0.2'
run: python -m pip install jinja2==3.0.3 markupsafe==2.0.1 pydata-sphinx-theme==0.8.0
run: python -m pip install jinja2==3.0.3 markupsafe==2.0.1 pydata-sphinx-theme==0.8.0 docutils==0.17.1

- name: Install
run: |
Expand Down Expand Up @@ -64,6 +72,59 @@ jobs:
make -C doc html SPHINXOPTS="-nT"
make -C doc latexpdf SPHINXOPTS="-nT"
test-new:
runs-on: ${{ matrix.os }}-latest
strategy:
matrix:
os: [Ubuntu]
python-version: ["3.10"]
sphinx-version:
["sphinx==4.2", "sphinx==4.5", "sphinx==5.0", "sphinx>=5.0"]
steps:
- uses: actions/checkout@v3

- name: Python setup
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}

- name: Setup environment
run: |
python -m pip install --upgrade pip wheel setuptools
python -m pip install -r requirements/test.txt -r doc/requirements.txt
python -m pip install codecov
python -m pip install ${{ matrix.sphinx-version }}
python -m pip list
- name: Install
run: |
python -m pip install .
pip list
- name: Run test suite
run: |
pytest -v --pyargs .
- name: Test coverage
run: |
codecov
- name: Make sure CLI works
run: |
python -m numpydoc numpydoc.tests.test_main._capture_stdout
echo '! python -m numpydoc numpydoc.tests.test_main._invalid_docstring' | bash
python -m numpydoc --validate numpydoc.tests.test_main._capture_stdout
echo '! python -m numpydoc --validate numpydoc.tests.test_main._docstring_with_errors' | bash
- name: Setup for doc build
run: |
sudo apt-get update
sudo apt install texlive texlive-latex-extra latexmk dvipng
- name: Build documentation
run: |
make -C doc html SPHINXOPTS="-nT"
make -C doc latexpdf SPHINXOPTS="-nT"
base:
runs-on: ${{ matrix.os }}-latest
strategy:
Expand Down

0 comments on commit a4dd122

Please sign in to comment.