Skip to content

Commit ddacbe8

Browse files
committed
run all test apps on CI
1 parent 5c29684 commit ddacbe8

File tree

3 files changed

+203
-142
lines changed

3 files changed

+203
-142
lines changed

.github/workflows/test-python.yml

Lines changed: 0 additions & 142 deletions
Original file line numberDiff line numberDiff line change
@@ -1,142 +0,0 @@
1-
name: Python Tests
2-
3-
on:
4-
pull_request:
5-
workflow_dispatch:
6-
7-
concurrency:
8-
group: tests-${{ github.ref }}
9-
cancel-in-progress: true
10-
11-
defaults:
12-
run:
13-
shell: bash -eux {0}
14-
15-
jobs:
16-
17-
lint:
18-
runs-on: ubuntu-latest
19-
steps:
20-
- uses: actions/checkout@v4
21-
- uses: actions/setup-python@v5
22-
with:
23-
python-version: '3.10'
24-
cache: 'pip'
25-
cache-dependency-path: 'pyproject.toml'
26-
- name: Install Python dependencies
27-
run: |
28-
python -m pip install -U pip pre-commit
29-
- name: Run linters
30-
run: |
31-
pre-commit run --hook-stage=manual --all-files
32-
33-
build:
34-
name: Django Test Suite
35-
runs-on: ubuntu-latest
36-
steps:
37-
- name: Checkout django-mongodb
38-
uses: actions/checkout@v4
39-
- name: install the django-mongodb backend
40-
run: |
41-
pip3 install --upgrade pip
42-
pip3 install -e .
43-
- name: Checkout Django
44-
uses: actions/checkout@v4
45-
with:
46-
repository: 'mongodb-forks/django'
47-
ref: 'mongodb-5.0.x'
48-
path: 'django_repo'
49-
- name: Install system packages for Django's Python test dependencies
50-
run: |
51-
sudo apt-get update
52-
sudo apt-get install libmemcached-dev
53-
- name: Install Django and its Python test dependencies
54-
run: |
55-
cd django_repo/tests/
56-
pip3 install -e ..
57-
pip3 install -r requirements/py3.txt
58-
- name: Copy the test settings file
59-
run: cp .github/workflows/mongodb_settings.py django_repo/tests/
60-
- name: Start MongoDB
61-
uses: supercharge/[email protected]
62-
with:
63-
mongodb-version: 5.0
64-
- name: Run tests
65-
run: >
66-
python3 django_repo/tests/runtests.py --settings mongodb_settings -v 2
67-
aggregation
68-
aggregation_regress
69-
annotations
70-
auth_tests.test_models.UserManagerTestCase
71-
backends
72-
basic
73-
bulk_create
74-
custom_pk
75-
dates
76-
datetimes
77-
db_functions
78-
delete
79-
delete_regress
80-
empty
81-
expressions
82-
expressions_case
83-
defer
84-
defer_regress
85-
force_insert_update
86-
from_db_value
87-
generic_relations
88-
generic_relations_regress
89-
introspection
90-
known_related_objects
91-
lookup
92-
m2m_and_m2o
93-
m2m_intermediary
94-
m2m_multiple
95-
m2m_recursive
96-
m2m_regress
97-
m2m_signals
98-
m2m_through
99-
m2m_through_regress
100-
m2o_recursive
101-
many_to_many
102-
many_to_one
103-
many_to_one_null
104-
migrations
105-
model_fields
106-
model_forms
107-
mutually_referential
108-
nested_foreign_keys
109-
null_fk
110-
null_fk_ordering
111-
null_queries
112-
one_to_one
113-
ordering
114-
or_lookups
115-
queries
116-
schema
117-
select_related
118-
select_related_onetoone
119-
select_related_regress
120-
sessions_tests
121-
timezones
122-
update
123-
xor_lookups
124-
125-
docs:
126-
name: Docs Checks
127-
runs-on: ubuntu-latest
128-
steps:
129-
- uses: actions/checkout@v4
130-
- uses: actions/setup-python@v5
131-
with:
132-
cache: 'pip'
133-
cache-dependency-path: 'pyproject.toml'
134-
python-version: '3.10'
135-
- name: Install dependencies
136-
run: |
137-
pip install -U pip
138-
pip install -e ".[docs]"
139-
- name: Build docs
140-
run: |
141-
cd docs
142-
make html

.github/workflows/test-python1.yml

Lines changed: 149 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,149 @@
1+
name: Python Tests II
2+
3+
on:
4+
pull_request:
5+
workflow_dispatch:
6+
7+
concurrency:
8+
group: tests1-${{ github.ref }}
9+
cancel-in-progress: true
10+
11+
defaults:
12+
run:
13+
shell: bash -eux {0}
14+
15+
jobs:
16+
17+
lint:
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: actions/checkout@v4
21+
- uses: actions/setup-python@v5
22+
with:
23+
python-version: '3.10'
24+
cache: 'pip'
25+
cache-dependency-path: 'pyproject.toml'
26+
- name: Install Python dependencies
27+
run: |
28+
python -m pip install -U pip pre-commit
29+
- name: Run linters
30+
run: |
31+
pre-commit run --hook-stage=manual --all-files
32+
33+
build:
34+
name: Django Test Suite
35+
runs-on: ubuntu-latest
36+
steps:
37+
- name: Checkout django-mongodb
38+
uses: actions/checkout@v4
39+
- name: install the django-mongodb backend
40+
run: |
41+
pip3 install --upgrade pip
42+
pip3 install -e .
43+
- name: Checkout Django
44+
uses: actions/checkout@v4
45+
with:
46+
repository: 'mongodb-forks/django'
47+
ref: 'mongodb-5.0.x'
48+
path: 'django_repo'
49+
- name: Install system packages for Django's Python test dependencies
50+
run: |
51+
sudo apt-get update
52+
sudo apt-get install libmemcached-dev
53+
- name: Install Django and its Python test dependencies
54+
run: |
55+
cd django_repo/tests/
56+
pip3 install -e ..
57+
pip3 install -r requirements/py3.txt
58+
- name: Copy the test settings file
59+
run: cp .github/workflows/mongodb_settings.py django_repo/tests/
60+
- name: Start MongoDB
61+
uses: supercharge/[email protected]
62+
with:
63+
mongodb-version: 5.0
64+
- name: Run tests
65+
run: >
66+
python3 django_repo/tests/runtests.py --settings mongodb_settings -v 2
67+
admin_checks
68+
admin_custom_urls
69+
admin_docs
70+
admin_ordering
71+
admin_scripts
72+
admin_utils
73+
admin_widgets
74+
check_framework
75+
contenttypes_tests
76+
context_processors
77+
custom_columns
78+
custom_managers
79+
datatypes
80+
dbshell
81+
empty_models
82+
file_uploads
83+
flatpages_tests
84+
forms_tests
85+
generic_inline_admin
86+
get_earliest_or_latest
87+
get_object_or_404
88+
get_or_create
89+
i18n
90+
inline_formsets
91+
managers_regress
92+
managers_regress
93+
max_lengths
94+
messages_tests
95+
migrate_signals
96+
migration_test_data_persistence
97+
model_formsets
98+
model_formsets_regress
99+
model_indexes
100+
model_inheritance_regress
101+
model_options
102+
model_package
103+
model_regress
104+
model_utils
105+
multiple_database
106+
order_with_respect_to
107+
pagination
108+
properties
109+
proxy_models
110+
redirects_tests
111+
reserved_names
112+
reverse_lookup
113+
save_delete_hooks
114+
signals
115+
sitemaps_tests
116+
sites_framework
117+
sites_tests
118+
str
119+
string_lookup
120+
swappable_models
121+
syndication_tests
122+
test_client
123+
test_client_regress
124+
test_runner
125+
test_utils
126+
transactions
127+
unmanaged_models
128+
update_only_fields
129+
user_commands
130+
view_tests
131+
132+
docs:
133+
name: Docs Checks
134+
runs-on: ubuntu-latest
135+
steps:
136+
- uses: actions/checkout@v4
137+
- uses: actions/setup-python@v5
138+
with:
139+
cache: 'pip'
140+
cache-dependency-path: 'pyproject.toml'
141+
python-version: '3.10'
142+
- name: Install dependencies
143+
run: |
144+
pip install -U pip
145+
pip install -e ".[docs]"
146+
- name: Build docs
147+
run: |
148+
cd docs
149+
make html

0 commit comments

Comments
 (0)