feat: release tagging via catalog-info.yaml and remove openedx.yaml #1062
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Python CI | |
on: | |
push: | |
branches: [master] | |
pull_request: | |
branches: | |
- '**' | |
workflow_dispatch: | |
branches: | |
- '**' | |
defaults: | |
run: | |
shell: bash # opts into error checking | |
jobs: | |
run_tests: | |
name: tests | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-20.04] | |
python-version: | |
- '3.8' | |
- '3.11' | |
toxenv: [py, quality] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: setup python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install pip | |
run: pip install -r requirements/pip.txt | |
- name: Install Dependencies | |
run: pip install -r requirements/ci.txt | |
- name: Run Tests | |
env: | |
TOXENV: ${{ matrix.toxenv }} | |
run: tox | |
# Tests that used to be in the cookiecutter-django-ida Makefile but | |
# that have not yet been moved into the regular unit tests (which | |
# would require some more work.) | |
run_ida_tests: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-20.04] | |
python-version: | |
- '3.8' | |
- '3.11' | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Generate demo project | |
run: | | |
make requirements | |
cookiecutter cookiecutter-django-ida --no-input | |
- name: "Post-gen: Virtualenv, and set up requirements" | |
working-directory: repo_name | |
run: | | |
virtualenv .venv | |
source .venv/bin/activate | |
make upgrade # TODO should be part of initial cookiecutter setup | |
make requirements | |
- name: "Post-gen: Migrations" | |
working-directory: repo_name | |
run: | | |
source .venv/bin/activate | |
python manage.py makemigrations | |
make migrate | |
- name: "Quality checks" | |
working-directory: repo_name | |
run: | | |
source .venv/bin/activate | |
make validate | |
- name: "Ensure translations can be compiled" | |
working-directory: repo_name | |
run: | | |
source .venv/bin/activate | |
sudo apt install gettext # required for msguniq, called by makemessages management command | |
make fake_translations | |
- name: "Ensure docker can build a container" | |
working-directory: repo_name | |
run: | | |
source .venv/bin/activate | |
docker build . --target app |