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

Switch integration and upgrade tests from CircleCI to GitHub actions #673

Merged
merged 5 commits into from
Apr 2, 2021
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
149 changes: 0 additions & 149 deletions .circleci/config.yml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def run_container_command(container_name, cmd):
"""
proc = subprocess.run([
'docker', 'exec',
'-it', container_name,
'-t', container_name,
'/bin/bash', '-c', cmd
], check=True)

Expand Down
41 changes: 41 additions & 0 deletions .github/workflows/integration-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
on:
pull_request:
push:
workflow_dispatch:

jobs:
integration-test:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: 3.6
- name: Set BOOTSTRAP_PIP_SPEC value
run: |
echo "BOOTSTRAP_PIP_SPEC=git+https://github.com/$GITHUB_ACTOR/the-littlest-jupyterhub.git@$GITHUB_SHA" >> $GITHUB_ENV
- name: Build systemd image
run: |
.github/integration-test.py build-image
- name: Run bootstrap checks
run: |
python3 -m pip install pytest
pytest integration-tests/test_bootstrap.py -s
- name: Run basic tests
run: |
.github/integration-test.py run-test \
--bootstrap-pip-spec "$BOOTSTRAP_PIP_SPEC" \
basic-tests test_hub.py test_proxy.py \
test_install.py test_extensions.py
- name: Run admin tests
run: |
.github/integration-test.py run-test \
--installer-args "--admin admin:admin" \
--bootstrap-pip-spec "$BOOTSTRAP_PIP_SPEC" \
basic-tests test_admin_installer.py \
- name: Run plugin tests
run: |
.github/integration-test.py run-test \
--bootstrap-pip-spec "$BOOTSTRAP_PIP_SPEC" \
--installer-args "--plugin /srv/src/integration-tests/plugins/simplest" \
plugins test_simplest_plugin.py \
41 changes: 41 additions & 0 deletions .github/workflows/upgrade-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
on:
pull_request:
push:
workflow_dispatch:

jobs:
upgrade-test:
if: ${{ github.ref != 'refs/heads/master' }}
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: 3.6
- name: Set BOOTSTRAP_PIP_SPEC value
run: |
echo "BOOTSTRAP_PIP_SPEC=git+https://github.com/$GITHUB_ACTOR/the-littlest-jupyterhub.git@$GITHUB_SHA" >> $GITHUB_ENV
- name: Build systemd image
run: |
.github/integration-test.py build-image
- name: Run basic tests
run: |
.github/integration-test.py run-test \
--bootstrap-pip-spec "$BOOTSTRAP_PIP_SPEC" \
basic-tests test_hub.py test_proxy.py \
test_install.py test_extensions.py \
--upgrade
- name: Run admin tests
run: |
.github/integration-test.py run-test \
--installer-args "--admin admin:admin" \
--bootstrap-pip-spec "$BOOTSTRAP_PIP_SPEC" \
basic-tests test_admin_installer.py \
--upgrade
- name: Run plugin tests
run: |
.github/integration-test.py run-test \
--bootstrap-pip-spec "$BOOTSTRAP_PIP_SPEC" \
--installer-args "--plugin /srv/src/integration-tests/plugins/simplest" \
plugins test_simplest_plugin.py \
--upgrade