Skip to content

test: run tests for python3.12 #252

test: run tests for python3.12

test: run tests for python3.12 #252

Workflow file for this run

name: codejail-ci
on:
push:
branches:
- master
pull_request:
jobs:
codejail_ci:
name: tests
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
python_version: ['3.11', '3.12']
ubuntu_version: ['20.04','22.04','24.04']
include:
- ubuntu_version: '20.04'
os: "ubuntu-20.04"
- ubuntu_version: '22.04'
os: "ubuntu-22.04"
- ubuntu_version: '24.04'
os: "ubuntu-24.04"
steps:
- uses: actions/checkout@v4
- name: Parse custom apparmor profile with default feature ABI
if: ${{ matrix.ubuntu_version == '20.04' }}
run: sudo apparmor_parser -r -W apparmor-profiles/home.sandbox.codejail-sandbox-venv.bin.python-default-abi
- name: Parse custom apparmor profile with ABI 3.0
if: ${{ matrix.ubuntu_version != '20.04' }}
run: sudo apparmor_parser -r -W apparmor-profiles/home.sandbox.codejail-sandbox-venv.bin.python-abi3
- name: Build latest code changes into CI image
run: |
docker build -t openedx-codejail \
--cache-to type=gha \
--cache-from type=gha \
--build-arg python_version=${{ matrix.python_version }} \
--build-arg ubuntu_version=${{ matrix.ubuntu_version }} .
- name: Run container with custom apparmor profile and codejail CI image
run: |
docker run --name=codejail --privileged -d --security-opt apparmor=apparmor_profile \
openedx-codejail tail -f /dev/null
- name: Run Non Proxy Tests
run: docker exec -t codejail bash -c 'make clean && make test_no_proxy'
- name: Run Proxy Tests
run: docker exec -t codejail bash -c 'make clean && make test_proxy'
- name: Run Quality Tests
run: docker exec -t codejail bash -c 'make quality'