missed these changes in the last commit

This commit is contained in:
CocoByte 2023-10-27 11:24:10 -06:00
parent 72ae138991
commit b236be7f43
No known key found for this signature in database
GPG key ID: BBFAA2526384C97F
3 changed files with 16 additions and 25 deletions

View file

@ -296,7 +296,7 @@ class Command(BaseCommand):
# TODO: make this somehow run inside TerminalHelper prompt
call_command(
command_script,
s=True
send_emails=True
)
def run_migration_scripts(self,

View file

@ -61,15 +61,6 @@ class TerminalHelper:
# DEBUG:
if print_condition:
logger.info(print_statement)
def execute_command(command_string:str):
"""Executes the given command string"""
logger.info(f"""{TerminalColors.OKCYAN}
==== EXECUTING... ====
{TerminalColors.ENDC}""")
os.system(f"{command_string}")
def prompt_for_execution(system_exit_on_terminate: bool,

View file

@ -138,21 +138,21 @@ class TestLogins(TestCase):
self.run_master_script()
# TODO: instead of patching....there has got to be a way of making sure subsequent commands use the django database
# Patch subroutines for migrations
def side_effect():
self.run_load_domains()
self.run_transfer_domains()
patcher = patch("registrar.management.commands.master_domain_migrations.Command.run_migration_scripts")
mocked_get = patcher.start()
mocked_get.side_effect = side_effect
# Patch subroutines for sending invitations
def side_effect():
# TODO: what should happen here?
return
patcher = patch("registrar.management.commands.master_domain_migrations.Command.run_send_invites_script")
mocked_get = patcher.start()
mocked_get.side_effect = side_effect
# # TODO: instead of patching....there has got to be a way of making sure subsequent commands use the django database
# # Patch subroutines for migrations
# def side_effect():
# self.run_load_domains()
# self.run_transfer_domains()
# patcher = patch("registrar.management.commands.master_domain_migrations.Command.run_migration_scripts")
# mocked_get = patcher.start()
# mocked_get.side_effect = side_effect
# # Patch subroutines for sending invitations
# def side_effect():
# # TODO: what should happen here?
# return
# patcher = patch("registrar.management.commands.master_domain_migrations.Command.run_send_invites_script")
# mocked_get = patcher.start()
# mocked_get.side_effect = side_effect
# STEP 2: (analyze the tables just like the migration script does, but add assert statements)
expected_total_transition_domains = 8