From 3541a10d492db6d1f509f3a50a024568c16c5229 Mon Sep 17 00:00:00 2001 From: Carl Meyer Date: Mon, 22 Oct 2012 18:13:59 -0600 Subject: Fixed #19164 -- Fixed diffsettings command broken in fix for #18545. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Thanks Mario César for the report and draft patch. --- tests/regressiontests/admin_scripts/tests.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'tests/regressiontests/admin_scripts') diff --git a/tests/regressiontests/admin_scripts/tests.py b/tests/regressiontests/admin_scripts/tests.py index 6f524bea29..a5deba7fe1 100644 --- a/tests/regressiontests/admin_scripts/tests.py +++ b/tests/regressiontests/admin_scripts/tests.py @@ -1603,3 +1603,15 @@ class StartProject(LiveServerTestCase, AdminScriptTestCase): with codecs.open(path, 'r', 'utf-8') as f: self.assertEqual(f.read(), 'Some non-ASCII text for testing ticket #18091:\nüäö €\n') + + +class DiffSettings(AdminScriptTestCase): + """Tests for diffsettings management command.""" + def test_basic(self): + "Runs without error and emits settings diff." + self.write_settings('settings_to_diff.py', sdict={'FOO': '"bar"'}) + args = ['diffsettings', '--settings=settings_to_diff'] + out, err = self.run_manage(args) + self.remove_settings('settings_to_diff.py') + self.assertNoOutput(err) + self.assertOutput(out, "FOO = 'bar' ###") -- cgit v1.3