Skip to content

Commit

Permalink
Include test-no-myst and test-no-kernel in test-pip
Browse files Browse the repository at this point in the history
with matrix.include
  • Loading branch information
mwouts committed Jun 21, 2023
1 parent c7f719f commit 77c7142
Showing 1 changed file with 17 additions and 82 deletions.
99 changes: 17 additions & 82 deletions .github/workflows/continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,13 @@ jobs:
runs-on: ubuntu-latest
permissions:
security-events: write

steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: python, javascript

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2

Expand All @@ -47,6 +44,15 @@ jobs:
strategy:
matrix:
python-version: [ 3.7, 3.8, 3.9, "3.10", "3.11"]
markdown-it-py-version: [2]
kernel: [true]
include:
- python-version: 3.9
markdown-it-py-version: [0,3]
- python-version: 3.9
kernel: false
- python-version: 3.9
quarto: true
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand All @@ -58,16 +64,22 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt
# All dependencies but markdown-it-py
python -m pip install nbformat pyyaml toml
python -m pip install -r requirements-dev.txt
# install sphinx_gallery and matplotlib if available (may not work on pypy)
# install sphinx_gallery and matplotlib if available
python -m pip install sphinx_gallery~=0.7.0 || true
python -m pip install jupyter-fs || true
- name: Install markdown-it-py
if: ${{ matrix.markdown-it-py-version }}
run: python -m pip install markdown-it-py==${{ matrix.markdown-it-py-version }}
- name: Install from source (required for the pre-commit tests)
run: python -m pip install .
- name: Install a Jupyter Kernel
if: ${{ matrix.kernel }}
run: python -m ipykernel install --name python_kernel --user
- name: Install Quarto
if: ${{ matrix.quarto }}
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
run: |
Expand Down Expand Up @@ -128,83 +140,6 @@ jobs:
uses: codecov/codecov-action@v3
if: ${{ matrix.os != 'windows-latest' }}

test-pip-no-myst:
needs: test-pip
strategy:
matrix:
python-version: [ 3.9 ]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies, except markdown-it-py
run: |
python -m pip install --upgrade pip
# All dependencies but markdown-it-py
python -m pip install nbformat pyyaml toml
python -m pip install -r requirements-dev.txt
- name: Install a Jupyter Kernel
run: python -m ipykernel install --name python_kernel --user
- name: Test with pytest
run: pytest --cov=./ --cov-report=xml
- name: Upload coverage
uses: codecov/codecov-action@v3

test-pip-no-kernel:
needs: test-pip
strategy:
matrix:
python-version: [ 3.9 ]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt
python -m pip install -r requirements-dev.txt
- name: Test with pytest
run: pytest --cov=./ --cov-report=xml
- name: Upload coverage
uses: codecov/codecov-action@v3

test-pip-notebook-pre:
needs: test-pip
strategy:
matrix:
python-version: [ 3.9 ]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
# All dependencies but markdown-it-py
python -m pip install -r requirements.txt
python -m pip install -r requirements-dev.txt
# Notebook pre-release version #933
python -m pip install --pre -U notebook
- name: Install a Jupyter Kernel
run: python -m ipykernel install --name python_kernel --user
- name: Test with pytest
run: pytest --cov=./ --cov-report=xml
- name: Upload coverage
uses: codecov/codecov-action@v3

build:
name: Build
needs: test-pip
Expand Down

0 comments on commit 77c7142

Please sign in to comment.