|
@@ -282,14 +282,14 @@ class DjangoAdminDefaultSettings(AdminScriptTestCase):
|
|
|
args = ['noargs_command', '--settings=test_project.settings']
|
|
|
out, err = self.run_django_admin(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
def test_custom_command_with_environment(self):
|
|
|
"default: django-admin can execute user commands if settings are provided in environment"
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_django_admin(args, 'test_project.settings')
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
|
|
|
class DjangoAdminFullPathDefaultSettings(AdminScriptTestCase):
|
|
@@ -349,14 +349,14 @@ class DjangoAdminFullPathDefaultSettings(AdminScriptTestCase):
|
|
|
args = ['noargs_command', '--settings=test_project.settings']
|
|
|
out, err = self.run_django_admin(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
def test_custom_command_with_environment(self):
|
|
|
"fulldefault: django-admin can execute user commands if settings are provided in environment"
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_django_admin(args, 'test_project.settings')
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
|
|
|
class DjangoAdminMinimalSettings(AdminScriptTestCase):
|
|
@@ -483,14 +483,14 @@ class DjangoAdminAlternateSettings(AdminScriptTestCase):
|
|
|
args = ['noargs_command', '--settings=test_project.alternate_settings']
|
|
|
out, err = self.run_django_admin(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
def test_custom_command_with_environment(self):
|
|
|
"alternate: django-admin can execute user commands if settings are provided in environment"
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_django_admin(args, 'test_project.alternate_settings')
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
|
|
|
class DjangoAdminMultipleSettings(AdminScriptTestCase):
|
|
@@ -553,14 +553,14 @@ class DjangoAdminMultipleSettings(AdminScriptTestCase):
|
|
|
args = ['noargs_command', '--settings=test_project.alternate_settings']
|
|
|
out, err = self.run_django_admin(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
def test_custom_command_with_environment(self):
|
|
|
"alternate: django-admin can execute user commands if settings are provided in environment"
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_django_admin(args, 'test_project.alternate_settings')
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
|
|
|
class DjangoAdminSettingsDirectory(AdminScriptTestCase):
|
|
@@ -718,21 +718,21 @@ class ManageDefaultSettings(AdminScriptTestCase):
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_manage(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
def test_custom_command_with_settings(self):
|
|
|
"default: manage.py can execute user commands when settings are provided as argument"
|
|
|
args = ['noargs_command', '--settings=test_project.settings']
|
|
|
out, err = self.run_manage(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
def test_custom_command_with_environment(self):
|
|
|
"default: manage.py can execute user commands when settings are provided in environment"
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_manage(args, 'test_project.settings')
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
|
|
|
class ManageFullPathDefaultSettings(AdminScriptTestCase):
|
|
@@ -785,21 +785,21 @@ class ManageFullPathDefaultSettings(AdminScriptTestCase):
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_manage(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
def test_custom_command_with_settings(self):
|
|
|
"fulldefault: manage.py can execute user commands when settings are provided as argument"
|
|
|
args = ['noargs_command', '--settings=test_project.settings']
|
|
|
out, err = self.run_manage(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
def test_custom_command_with_environment(self):
|
|
|
"fulldefault: manage.py can execute user commands when settings are provided in environment"
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_manage(args, 'test_project.settings')
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
|
|
|
class ManageMinimalSettings(AdminScriptTestCase):
|
|
@@ -929,21 +929,21 @@ class ManageAlternateSettings(AdminScriptTestCase):
|
|
|
"alternate: manage.py can execute user commands if settings are provided as argument"
|
|
|
args = ['noargs_command', '--settings=alternate_settings']
|
|
|
out, err = self.run_manage(args)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand options=[('no_color', False), ('pythonpath', None), ('settings', 'alternate_settings'), ('traceback', False), ('verbosity', 1)]")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command options=[('no_color', False), ('pythonpath', None), ('settings', 'alternate_settings'), ('traceback', False), ('verbosity', 1)]")
|
|
|
self.assertNoOutput(err)
|
|
|
|
|
|
def test_custom_command_with_environment(self):
|
|
|
"alternate: manage.py can execute user commands if settings are provided in environment"
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_manage(args, 'alternate_settings')
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand options=[('no_color', False), ('pythonpath', None), ('settings', None), ('traceback', False), ('verbosity', 1)]")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command options=[('no_color', False), ('pythonpath', None), ('settings', None), ('traceback', False), ('verbosity', 1)]")
|
|
|
self.assertNoOutput(err)
|
|
|
|
|
|
def test_custom_command_output_color(self):
|
|
|
"alternate: manage.py output syntax color can be deactivated with the `--no-color` option"
|
|
|
args = ['noargs_command', '--no-color', '--settings=alternate_settings']
|
|
|
out, err = self.run_manage(args)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand options=[('no_color', True), ('pythonpath', None), ('settings', 'alternate_settings'), ('traceback', False), ('verbosity', 1)]")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command options=[('no_color', True), ('pythonpath', None), ('settings', 'alternate_settings'), ('traceback', False), ('verbosity', 1)]")
|
|
|
self.assertNoOutput(err)
|
|
|
|
|
|
|
|
@@ -1008,14 +1008,14 @@ class ManageMultipleSettings(AdminScriptTestCase):
|
|
|
args = ['noargs_command', '--settings=alternate_settings']
|
|
|
out, err = self.run_manage(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
def test_custom_command_with_environment(self):
|
|
|
"multiple: manage.py can execute user commands if settings are provided in environment"
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_manage(args, 'alternate_settings')
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command")
|
|
|
|
|
|
|
|
|
class ManageSettingsWithSettingsErrors(AdminScriptTestCase):
|
|
@@ -1496,7 +1496,7 @@ class CommandTypes(AdminScriptTestCase):
|
|
|
args = ['noargs_command']
|
|
|
out, err = self.run_manage(args)
|
|
|
self.assertNoOutput(err)
|
|
|
- self.assertOutput(out, "EXECUTE:NoArgsCommand options=[('no_color', False), ('pythonpath', None), ('settings', None), ('traceback', False), ('verbosity', 1)]")
|
|
|
+ self.assertOutput(out, "EXECUTE: noargs_command options=[('no_color', False), ('pythonpath', None), ('settings', None), ('traceback', False), ('verbosity', 1)]")
|
|
|
|
|
|
def test_noargs_with_args(self):
|
|
|
"NoArg Commands raise an error if an argument is provided"
|