add ObjectIdField #739
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 Tests | |
on: | |
pull_request: | |
paths: | |
- '**.py' | |
- '!setup.py' | |
- '.github/workflows/test-python.yml' | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
defaults: | |
run: | |
shell: bash -eux {0} | |
jobs: | |
build: | |
name: Django Test Suite | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout django-mongodb | |
uses: actions/checkout@v4 | |
with: | |
persist-credentials: false | |
- name: install the django-mongodb backend | |
run: | | |
pip3 install --upgrade pip | |
pip3 install -e . | |
- name: Checkout Django | |
uses: actions/checkout@v4 | |
with: | |
repository: 'wavev/django' | |
ref: 'add-ObjectIdField' | |
path: 'django_repo' | |
persist-credentials: false | |
- name: Install system packages for Django's Python test dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install libmemcached-dev | |
- name: Install Django and its Python test dependencies | |
run: | | |
cd django_repo/tests/ | |
pip3 install -e .. | |
pip3 install -r requirements/py3.txt | |
- name: Copy the test settings file | |
run: cp .github/workflows/mongodb_settings.py django_repo/tests/ | |
- name: Copy the test runner file | |
run: cp .github/workflows/runtests.py django_repo/tests/runtests_.py | |
- name: Start MongoDB | |
uses: supercharge/[email protected] | |
with: | |
mongodb-version: 5.0 | |
- name: Run tests | |
run: python3 django_repo/tests/runtests_.py |