Skip to content

Commit

Permalink
Fix CI
Browse files Browse the repository at this point in the history
  • Loading branch information
martinRenou committed Mar 29, 2022
1 parent 2540db9 commit 038b783
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 21 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ jobs:
- name: Mamba install dependencies
run: mamba install python=${{ matrix.python-version }} pip nodejs flake8

- name: Mamba install JupyterLab 3
run: mamba install jupyterlab=3 ipywidgets=7.6 openssl=1.1.1l
- name: Mamba install dependencies
run: mamba install jupyterlab ipywidgets openssl=1.1.1l

- name: Install ipyleaflet
run: pip install .
Expand Down
42 changes: 26 additions & 16 deletions .github/workflows/ui-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ name: UI Tests

on: [push, pull_request]


defaults:
run:
shell: bash -l {0}

jobs:
ui-tests:
name: Visual Regression
Expand All @@ -17,22 +22,30 @@ jobs:
- name: Base Setup
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1

- name: Setup conda
uses: conda-incubator/setup-miniconda@v2
with:
mamba-version: "*"
channels: conda-forge

- name: Mamba install dependencies
run: mamba install python=${{ matrix.python-version }} pip nodejs flake8

- name: Mamba install dependencies
run: mamba install jupyterlab ipywidgets openssl=1.1.1l

- name: Install ipyleaflet
run: |
python -m pip install --upgrade jupyterlab~=3.0 ipywidgets~=7.6
python -m pip install .
cd ui-tests
jlpm install
run: pip install .

- name: Install browser
run: |
cd ui-tests
jlpm install
jlpm playwright install chromium
working-directory: ui-tests

- name: Launch JupyterLab
run: |
cd ui-tests
jlpm start-jlab:detached > /tmp/jupyterlab_server.log 2>&1
run: jlpm start-jlab:detached > /tmp/jupyterlab_server.log 2>&1
working-directory: ui-tests

- name: Wait for JupyterLab
uses: ifaxity/wait-on-action@v1
Expand All @@ -41,10 +54,8 @@ jobs:
timeout: 360000

- name: Widget rendering tests
shell: bash
run: |
cd ui-tests
jlpm run test
run: jlpm run test
working-directory: ui-tests

- name: Upload Playwright Test assets
if: always()
Expand All @@ -65,13 +76,12 @@ jobs:
- name: Update snapshots
if: failure()
run: |
cd ui-tests
# remove previous snapshots from other browser
jlpm rimraf "tests/**/*-snapshots/*.png"
# generate new snapshots
jlpm run test:update
working-directory: ui-tests

- name: Print JupyterLab logs
if: always()
run: |
cat /tmp/jupyterlab_server.log
run: cat /tmp/jupyterlab_server.log
17 changes: 14 additions & 3 deletions .github/workflows/update_galata_references.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,21 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Install dependencies
- name: Setup conda
uses: conda-incubator/setup-miniconda@v2
with:
mamba-version: "*"
channels: conda-forge

- name: Mamba install dependencies
run: mamba install python=${{ matrix.python-version }} pip nodejs flake8

- name: Mamba install dependencies
run: mamba install jupyterlab ipywidgets openssl=1.1.1l

- name: Install ipyleaflet
run: |
python -m pip install --upgrade jupyterlab~=3.0 ipywidgets~=7.6
python -m pip install .
pip install .
jlpm
jlpm build
jupyter labextension develop . --overwrite
Expand Down

0 comments on commit 038b783

Please sign in to comment.