Skip to content

Commit c386123

Browse files
authored
feat: update workflow files to uniformly distribute the test modules by time taken by each test module (#615)
* fix: lint_setup_py was failing in Kokoro is not fixed * feat: rearranged test modules in workflow to uniformly distribute the time taken
1 parent 5b3b2e4 commit c386123

20 files changed

+16
-299
lines changed

.github/workflows/django_tests_against_emulator0.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: model_fields model_forms
32+
DJANGO_TEST_APPS: admin_changelist admin_ordering aggregation choices distinct_on_fields expressions_window fixtures_model_package datetimes custom_methods generic_inline_admin field_defaults datatypes empty m2o_recursive many_to_one_null migration_test_data_persistence admin_docs invalid_models_tests migrate_signals model_forms.test_uuid model_forms.test_modelchoicefield syndication_tests view_tests update test_utils select_related_onetoone sessions_tests

.github/workflows/django_tests_against_emulator1.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: mutually_referential nested_foreign_keys null_fk null_fk_ordering null_queries one_to_one ordering order_with_respect_to or_lookups
32+
DJANGO_TEST_APPS: db_functions save_delete_hooks get_object_or_404 model_indexes custom_pk indexes transaction_hooks constraints schema custom_columns i18n from_db_value sites_tests mutually_referential model_package defer_regress update_only_fields backends redirects_tests expressions get_or_create foreign_object generic_relations_regress many_to_many select_related generic_relations queryset_pickle model_inheritance

.github/workflows/django_tests_against_emulator10.yml

-32
This file was deleted.

.github/workflows/django_tests_against_emulator11.yml

-32
This file was deleted.

.github/workflows/django_tests_against_emulator12.yml

-32
This file was deleted.

.github/workflows/django_tests_against_emulator13.yml

-32
This file was deleted.

.github/workflows/django_tests_against_emulator14.yml

-32
This file was deleted.

.github/workflows/django_tests_against_emulator15.yml

-32
This file was deleted.

.github/workflows/django_tests_against_emulator16.yml

-32
This file was deleted.

.github/workflows/django_tests_against_emulator17.yml

-32
This file was deleted.

.github/workflows/django_tests_against_emulator18.yml

-32
This file was deleted.

.github/workflows/django_tests_against_emulator2.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: migration_test_data_persistence max_lengths migrate_signals select_for_update queries
32+
DJANGO_TEST_APPS: model_options known_related_objects m2m_signals delete_regress fixtures generic_views model_inheritance_regress nested_foreign_keys lookup delete model_formsets

.github/workflows/django_tests_against_emulator3.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: sitemaps_tests sites_framework sites_tests string_lookup syndication_tests test_client test_client_regress test_runner test_utils timezones
32+
DJANGO_TEST_APPS: signals or_lookups m2m_through_regress filtered_relation servers m2m_through fixtures_regress timezones model_forms.tests

.github/workflows/django_tests_against_emulator4.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: admin_inlines admin_ordering aggregation migrations
32+
DJANGO_TEST_APPS: introspection multiple_database null_fk_ordering ordering m2m_intermediary null_fk max_lengths dates force_insert_update test_client m2m_multiple test_client_regress sitemaps_tests admin_inlines transactions null_queries test_runner m2m_and_m2o prefetch_related m2m_regress file_uploads sites_framework auth_tests forms_tests inline_formsets order_with_respect_to contenttypes_tests defer

.github/workflows/django_tests_against_emulator5.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: custom_columns custom_managers custom_methods custom_pk datatypes dates datetimes db_functions defer defer_regress
32+
DJANGO_TEST_APPS: file_storage m2m_recursive reverse_lookup managers_regress basic annotations unmanaged_models string_lookup aggregation_regress reserved_names select_for_update many_to_one cache select_related_regress flatpages_tests model_formsets_regress

.github/workflows/django_tests_against_emulator6.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: fixtures fixtures_model_package fixtures_regress flatpages_tests force_insert_update
32+
DJANGO_TEST_APPS: model_fields queries.test_bulk_update queries.test_explain

.github/workflows/django_tests_against_emulator7.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: generic_views get_earliest_or_latest get_object_or_404 get_or_create i18n indexes inline_formsets inspectdb introspection invalid_models_tests
32+
DJANGO_TEST_APPS: queries.test_iterator queries.test_q queries.test_query queries.test_qs_combinators

.github/workflows/django_tests_against_emulator8.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: model_inheritance model_inheritance_regress model_options model_package multiple_database
32+
DJANGO_TEST_APPS: inspectdb custom_managers migrations validation get_earliest_or_latest proxy_model_inheritance one_to_one raw_query bulk_create

.github/workflows/django_tests_against_emulator9.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
GOOGLE_CLOUD_TESTS_CREATE_SPANNER_INSTANCE: true
3030
RUNNING_SPANNER_BACKEND_TESTS: 1
3131
SPANNER_TEST_INSTANCE: google-cloud-django-backend-tests
32-
DJANGO_TEST_APPS: prefetch_related proxy_model_inheritance
32+
DJANGO_TEST_APPS: queries.tests

django_test_suite.sh

+6-1
Original file line numberDiff line numberDiff line change
@@ -66,4 +66,9 @@ PASSWORD_HASHERS = [
6666
cd $TESTS_DIR/django/tests
6767
create_settings
6868

69-
python3 runtests.py $DJANGO_TEST_APPS --verbosity=3 --noinput --settings $SETTINGS_FILE
69+
EXIT_STATUS=0
70+
for DJANGO_TEST_APP in $DJANGO_TEST_APPS
71+
do
72+
python3 runtests.py $DJANGO_TEST_APP --verbosity=3 --noinput --settings $SETTINGS_FILE || EXIT_STATUS=$?
73+
done
74+
exit $EXIT_STATUS

0 commit comments

Comments
 (0)