diff options
| author | Aymeric Augustin <aymeric.augustin@m4x.org> | 2013-03-17 20:48:30 +0100 |
|---|---|---|
| committer | Aymeric Augustin <aymeric.augustin@m4x.org> | 2013-03-18 00:03:58 +0100 |
| commit | 20a91cce04c72bc8c64a1c43b7398edac7b709cc (patch) | |
| tree | d505ae2def12275bbec1610bd1c50850467abf72 /tests/admin_scripts/tests.py | |
| parent | 68905695b897e62b0c18d9edd87171a0eae4e67e (diff) | |
Fixed #17037 -- Added a --all option to diffsettings.
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") |
