-
-
Notifications
You must be signed in to change notification settings - Fork 341
63 lines (52 loc) · 1.55 KB
/
unit-tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Python Tests
# suppress warning raised by https://github.com/jupyter/jupyter_core/pull/292
env:
JUPYTER_PLATFORM_DIRS: "1"
on:
push:
branches: main
pull_request:
branches: "*"
jobs:
unit-tests:
name: Unit tests (Python ${{ matrix.python-version }}, ${{ matrix.dependency-type }} dependencies)
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- dependency-type: minimum
python-version: "3.9"
- dependency-type: standard
python-version: "3.12"
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
with:
python_version: ${{ matrix.python-version }}
dependency_type: ${{ matrix.dependency-type }}
- name: Install extension dependencies and build the extension
run: ./scripts/install.sh
- name: List installed versions
run: pip list
- name: Execute unit tests
run: |
set -eux
pytest -vv -r ap --cov jupyter_ai
typing-tests:
name: Typing test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
- name: Install extension dependencies and build the extension
run: ./scripts/install.sh
- name: Run mypy
run: |
set -eux
mypy --version
mypy packages/jupyter-ai