Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test against all kernels in jupyter kernel test and clean up CI #731

Merged
merged 7 commits into from
Jan 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 2 additions & 32 deletions .github/workflows/check-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,38 +17,8 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Python
uses: actions/setup-python@v2
with:
python-version: 3.9
architecture: "x64"
- name: Install node
uses: actions/setup-node@v2
with:
node-version: "14.x"
- name: Get pip cache dir
id: pip-cache
run: |
echo "::set-output name=dir::$(pip cache dir)"
- name: Cache pip
uses: actions/cache@v1
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-pip-${{ hashFiles('setup.cfg') }}
restore-keys: |
${{ runner.os }}-pip-
${{ runner.os }}-pip-
- name: Cache checked links
if: ${{ matrix.group == 'link_check' }}
uses: actions/cache@v2
with:
path: ~/.cache/pytest-link-check
key: ${{ runner.os }}-linkcheck-${{ hashFiles('**/*.md', '**/*.rst') }}-md-links
restore-keys: |
${{ runner.os }}-linkcheck-
- name: Upgrade packaging dependencies
run: |
pip install --upgrade pip setuptools wheel --user
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- name: Install Dependencies
run: |
pip install -e .
Expand Down
18 changes: 17 additions & 1 deletion .github/workflows/downstream.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ on:
jobs:
tests:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9"]

steps:
- name: Checkout
Expand Down Expand Up @@ -45,9 +48,22 @@ jobs:
with:
package_name: jupyter_server

# Test using jupyter_kernel_test

- name: Setup conda ${{ matrix.python-version }}
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
activate-environment: jupyter_kernel_test
miniforge-variant: Mambaforge
python-version: ${{ matrix.python-version }}

- name: Test jupyter_kernel_test
shell: bash -l {0}
run: |
git clone https://github.com/jupyter/jupyter_kernel_test.git
cd jupyter_kernel_test
conda env update --name jupyter_kernel_test --file environment.yml
conda install -c conda-forge xeus-cling
pip install -e ".[test]"
python test_ipykernel.py
python -m unittest -v
33 changes: 4 additions & 29 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: [3.6, 3.7, 3.8, 3.9]
python-version: [3.6, 3.7, 3.8, 3.9, "3.10"]

env:
OS: ${{ matrix.os }}
Expand All @@ -78,33 +78,8 @@ jobs:
- name: Checkout
uses: actions/checkout@v2

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

- name: Update pip
run: |
pip install --upgrade pip
pip install --upgrade wheel setuptools

- name: Get pip cache dir
id: pip-cache
run: |
echo "::set-output name=dir::$(pip cache dir)"

- name: Cache pip
uses: actions/cache@v2
with:
path: |
${{ steps.pip-cache.outputs.dir }}
.mypy_cache
key: ${{ runner.os }}-python-${{ matrix.python-version }}-pip-${{ hashFiles('**/requirements*.txt') }}-git-${{ github.sha }}
restore-keys: |
${{ runner.os }}-python-${{ matrix.python-version }}-pip-${{ hashFiles('**/requirements*.txt') }}
${{ runner.os }}-python-${{ matrix.python-version }}-pip-
${{ runner.os }}-python
${{ runner.os }}-
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1

- name: Install dependencies
run: |
Expand All @@ -114,7 +89,7 @@ jobs:
- name: Check types
run: mypy jupyter_client --exclude '\/tests|kernelspecapp|ioloop|runapp' --install-types --non-interactive

- name: Run the tests
- name: Run the tests with coverage
run: pytest --cov jupyter_client -v jupyter_client

- name: Build the docs
Expand Down