diff options
Diffstat (limited to 'tests/admin_scripts/tests.py')
| -rw-r--r-- | tests/admin_scripts/tests.py | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/tests/admin_scripts/tests.py b/tests/admin_scripts/tests.py index 90f77206cd..baec16820e 100644 --- a/tests/admin_scripts/tests.py +++ b/tests/admin_scripts/tests.py @@ -1661,11 +1661,21 @@ class StartProject(LiveServerTestCase, AdminScriptTestCase): class DiffSettings(AdminScriptTestCase): """Tests for diffsettings management command.""" + def test_basic(self): - "Runs without error and emits settings diff." + """Runs without error and emits settings diff.""" self.write_settings('settings_to_diff.py', sdict={'FOO': '"bar"'}) self.addCleanup(self.remove_settings, 'settings_to_diff.py') args = ['diffsettings', '--settings=settings_to_diff'] out, err = self.run_manage(args) self.assertNoOutput(err) self.assertOutput(out, "FOO = 'bar' ###") + + def test_all(self): + """The all option also shows settings with the default value.""" + self.write_settings('settings_to_diff.py', sdict={'STATIC_URL': 'None'}) + self.addCleanup(self.remove_settings, 'settings_to_diff.py') + args = ['diffsettings', '--settings=settings_to_diff', '--all'] + out, err = self.run_manage(args) + self.assertNoOutput(err) + self.assertOutput(out, "### STATIC_URL = None") |
