@@ -503,7 +503,7 @@ def test_enable_qe_activates_settings(tmp_path):
503503 "# INSTALLED_APPS += QE_INSTALLED_APPS # noqa: F405\n "
504504 )
505505 (settings_dir / "qe.py" ).write_text (
506- 'QE_INSTALLED_APPS = ["medical_records.django_only "]\n '
506+ 'QE_INSTALLED_APPS = ["medical_records.medical_records_django "]\n '
507507 )
508508
509509 _enable_qe (tmp_path , "myproject" )
@@ -515,7 +515,7 @@ def test_enable_qe_activates_settings(tmp_path):
515515
516516
517517def test_enable_qe_uses_django_app_by_default (tmp_path ):
518- """Test that _enable_qe leaves medical_records.django_only when wagtail=False."""
518+ """Test that _enable_qe leaves medical_records.medical_records_django when wagtail=False."""
519519 from dbx_python_cli .commands .project import _enable_qe
520520
521521 settings_dir = tmp_path / "myproject" / "settings"
@@ -525,15 +525,17 @@ def test_enable_qe_uses_django_app_by_default(tmp_path):
525525 "# INSTALLED_APPS += QE_INSTALLED_APPS # noqa: F405\n "
526526 )
527527 qe_file = settings_dir / "qe.py"
528- qe_file .write_text ('QE_INSTALLED_APPS = ["medical_records.django_only"]\n ' )
528+ qe_file .write_text (
529+ 'QE_INSTALLED_APPS = ["medical_records.medical_records_django"]\n '
530+ )
529531
530532 _enable_qe (tmp_path , "myproject" , wagtail = False )
531533
532- assert '"medical_records.django_only "' in qe_file .read_text ()
534+ assert '"medical_records.medical_records_django "' in qe_file .read_text ()
533535
534536
535537def test_enable_qe_uses_wagtail_app_when_stacked (tmp_path ):
536- """Test that _enable_qe replaces app with medical_records.wagtail when wagtail=True."""
538+ """Test that _enable_qe replaces app with medical_records.medical_records_wagtail when wagtail=True."""
537539 from dbx_python_cli .commands .project import _enable_qe
538540
539541 settings_dir = tmp_path / "myproject" / "settings"
@@ -543,13 +545,15 @@ def test_enable_qe_uses_wagtail_app_when_stacked(tmp_path):
543545 "# INSTALLED_APPS += QE_INSTALLED_APPS # noqa: F405\n "
544546 )
545547 qe_file = settings_dir / "qe.py"
546- qe_file .write_text ('QE_INSTALLED_APPS = ["medical_records.django_only"]\n ' )
548+ qe_file .write_text (
549+ 'QE_INSTALLED_APPS = ["medical_records.medical_records_django"]\n '
550+ )
547551
548552 _enable_qe (tmp_path , "myproject" , wagtail = True )
549553
550554 qe_content = qe_file .read_text ()
551- assert '"medical_records.wagtail "' in qe_content
552- assert '"medical_records.django_only "' not in qe_content
555+ assert '"medical_records.medical_records_wagtail "' in qe_content
556+ assert '"medical_records.medical_records_django "' not in qe_content
553557
554558
555559def test_create_pyproject_toml_includes_pymongocrypt_when_qe (tmp_path ):
@@ -579,10 +583,10 @@ def test_create_pyproject_toml_excludes_pymongocrypt_by_default(tmp_path):
579583
580584
581585def test_qe_with_medical_records_adds_django_app_to_installed_apps (tmp_path ):
582- """When --qe and --with medical-records are both used, medical_records.django_only must be in INSTALLED_APPS.
586+ """When --qe and --with medical-records are both used, medical_records.medical_records_django must be in INSTALLED_APPS.
583587
584588 _enable_qe uncomments the QE import block in the project settings, which adds
585- QE_INSTALLED_APPS (containing medical_records.django_only ) to INSTALLED_APPS.
589+ QE_INSTALLED_APPS (containing medical_records.medical_records_django ) to INSTALLED_APPS.
586590 """
587591 from dbx_python_cli .commands .project import _enable_qe
588592
@@ -594,11 +598,13 @@ def test_qe_with_medical_records_adds_django_app_to_installed_apps(tmp_path):
594598 "# INSTALLED_APPS += QE_INSTALLED_APPS # noqa: F405\n "
595599 )
596600 qe_file = settings_dir / "qe.py"
597- qe_file .write_text ('QE_INSTALLED_APPS = ["medical_records.django_only"]\n ' )
601+ qe_file .write_text (
602+ 'QE_INSTALLED_APPS = ["medical_records.medical_records_django"]\n '
603+ )
598604
599605 _enable_qe (tmp_path , "myproject" )
600606
601607 settings_content = settings_file .read_text ()
602608 assert "from .qe import * # noqa" in settings_content
603609 assert "INSTALLED_APPS += QE_INSTALLED_APPS # noqa: F405" in settings_content
604- assert '"medical_records.django_only "' in qe_file .read_text ()
610+ assert '"medical_records.medical_records_django "' in qe_file .read_text ()
0 commit comments