Rev 5454: Check error message if the test is checking for errors or we have unexpected success for wrong errors. in file:///home/vila/src/bzr/experimental/config/

Vincent Ladeuil v.ladeuil+lp at free.fr
Mon Oct 4 09:42:17 BST 2010


At file:///home/vila/src/bzr/experimental/config/

------------------------------------------------------------
revno: 5454
revision-id: v.ladeuil+lp at free.fr-20101004084217-z6ul10wq2f8h6nfv
parent: v.ladeuil+lp at free.fr-20101004080627-dmx49vve2127gcgc
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: config-modify
timestamp: Mon 2010-10-04 10:42:17 +0200
message:
  Check error message if the test is checking for errors or we have unexpected success for wrong errors.
-------------- next part --------------
=== modified file 'bzrlib/tests/blackbox/test_config.py'
--- a/bzrlib/tests/blackbox/test_config.py	2010-10-04 08:06:27 +0000
+++ b/bzrlib/tests/blackbox/test_config.py	2010-10-04 08:42:17 +0000
@@ -84,7 +84,8 @@
         _t_config.create_configs(self)
 
     def test_unknown_config(self):
-        self.run_bzr(['config', '--force', 'moon', 'hello=world'], retcode=3)
+        self.run_bzr_error(['moon is not a known configuration'],
+                           ['config', '--force', 'moon', 'hello=world'])
 
     def test_bazaar_config_outside_branch(self):
         script.run_script(self, '''
@@ -134,4 +135,5 @@
         _t_config.create_configs_with_file_option(self)
 
     def test_unknown_option(self):
-        self.run_bzr(['config', '--remove', 'file'], retcode=3)
+        self.run_bzr_error(['file option is unknown',],
+                           ['config', '--remove', 'file'])

=== modified file 'bzrlib/tests/test_config.py'
--- a/bzrlib/tests/test_config.py	2010-10-04 08:06:27 +0000
+++ b/bzrlib/tests/test_config.py	2010-10-04 08:42:17 +0000
@@ -1569,6 +1569,7 @@
         super(TestConfigRemoveOption, self).setUp()
         create_configs_with_file_option(self)
 
+
 class TestConfigGetSections(tests.TestCaseWithTransport):
 
     def setUp(self):



More information about the bazaar-commits mailing list