mirror of
https://github.com/django/django.git
synced 2025-08-30 23:37:50 +00:00
Made startapp/project's overlaying error message use 'app' or 'project'.
This commit is contained in:
parent
96446c7152
commit
03bee42a7e
2 changed files with 28 additions and 13 deletions
|
@ -1938,7 +1938,11 @@ class StartProject(LiveServerTestCase, AdminScriptTestCase):
|
|||
# running again..
|
||||
out, err = self.run_django_admin(args)
|
||||
self.assertNoOutput(out)
|
||||
self.assertOutput(err, "already exists")
|
||||
self.assertOutput(
|
||||
err,
|
||||
"already exists. Overlaying a project into an existing directory "
|
||||
"won't replace conflicting files."
|
||||
)
|
||||
|
||||
def test_custom_project_template(self):
|
||||
"Make sure the startproject management command is able to use a different project template"
|
||||
|
@ -2128,6 +2132,15 @@ class StartApp(AdminScriptTestCase):
|
|||
)
|
||||
self.assertFalse(os.path.exists(testproject_dir))
|
||||
|
||||
def test_overlaying_app(self):
|
||||
self.run_django_admin(['startapp', 'app1'])
|
||||
out, err = self.run_django_admin(['startapp', 'app2', 'app1'])
|
||||
self.assertOutput(
|
||||
err,
|
||||
"already exists. Overlaying an app into an existing directory "
|
||||
"won't replace conflicting files."
|
||||
)
|
||||
|
||||
|
||||
class DiffSettings(AdminScriptTestCase):
|
||||
"""Tests for diffsettings management command."""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue