]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[1443] Addressed review comments
authorJelte Jansen <jelte@isc.org>
Thu, 22 Mar 2012 14:36:43 +0000 (15:36 +0100)
committerJelte Jansen <jelte@isc.org>
Thu, 22 Mar 2012 14:36:43 +0000 (15:36 +0100)
- if self.clear_config is None was wrong, should just be if self.clear_config
- 'back up' should have been 'create backup of'
- default value for unused parameter rename_config_file in b10-cfgmgr_test.py.in MyConfigManager should have been False, not None
- reordered message file

src/bin/bind10/bind10_src.py.in
src/bin/cfgmgr/tests/b10-cfgmgr_test.py.in
src/lib/python/isc/config/cfgmgr_messages.mes

index 5a3f792b7d40f4786f2464a35ef349384c66398e..ddc6b7dc0580b7ecbbaff179e32ab24233e2ecf0 100755 (executable)
@@ -466,7 +466,7 @@ class BoB:
             args.append("--data-path=" + self.data_path)
         if self.config_filename is not None:
             args.append("--config-filename=" + self.config_filename)
-        if self.clear_config is not None:
+        if self.clear_config:
             args.append("--clear-config")
         bind_cfgd = ProcessInfo("b10-cfgmgr", args,
                                 self.c_channel_env)
@@ -1058,7 +1058,8 @@ def parse_args(args=sys.argv[1:], Parser=OptionParser):
                       help="Configuration database filename")
     parser.add_option("--clear-config", action="store_true",
                       dest="clear_config", default=False,
-                      help="Back up the configuration file and start with a clean one")
+                      help="Create backup of the configuration file and " +
+                           "start with a clean configuration")
     parser.add_option("-p", "--data-path", dest="data_path",
                       help="Directory to search for configuration files",
                       default=None)
index 141bf6e8e30d6eeb89169c6e51d0824bdaec2890..ca91c9c79f575f751e3f2be8f6b44f0f81dfe40b 100644 (file)
@@ -24,7 +24,7 @@ import bind10_config
 from isc.testutils.parse_args import OptsError, TestOptParser
 
 class MyConfigManager:
-    def __init__(self, path, filename, session=None, rename_config_file=None):
+    def __init__(self, path, filename, session=None, rename_config_file=False):
         self._path = path
         self.read_config_called = False
         self.notify_boss_called = False
index b307604dec0a3f10f6027a2fbf4545825da690fb..ad78be0be0198a62ed96885c98c16315a1452f53 100644 (file)
@@ -51,11 +51,11 @@ error is given. The most likely cause is that the system does not have
 write access to the configuration database file. The updated
 configuration is not stored.
 
-% CFGMGR_STOPPED_BY_KEYBOARD keyboard interrupt, shutting down
-There was a keyboard interrupt signal to stop the cfgmgr daemon. The
-daemon will now shut down.
-
 % CFGMGR_RENAMED_CONFIG_FILE renamed configuration file %1 to %2, will create new %1
 BIND 10 has been started with the command to clear the configuration file.
 The existing file is backed up to the given file name, so that data is not
 immediately lost if this was done by accident.
+
+% CFGMGR_STOPPED_BY_KEYBOARD keyboard interrupt, shutting down
+There was a keyboard interrupt signal to stop the cfgmgr daemon. The
+daemon will now shut down.