summaryrefslogtreecommitdiff
path: root/python/vyos/configtree.py
diff options
context:
space:
mode:
authorJohn Estabrook <jestabro@vyos.io>2023-03-19 20:06:57 -0500
committerJohn Estabrook <jestabro@vyos.io>2023-03-29 10:28:14 -0500
commitda43c4cbd495ce85f491c304de43e65ee1f39f08 (patch)
tree2ba111c7777e1d9e0f27a9354715aa9c4016e9f3 /python/vyos/configtree.py
parente5758160c8a25523df9c8cde9baf958466bf1881 (diff)
downloadvyos-1x-da43c4cbd495ce85f491c304de43e65ee1f39f08.tar.gz
vyos-1x-da43c4cbd495ce85f491c304de43e65ee1f39f08.zip
configdiff: T5089: add optional arg ordered_values for unit tests
Diffstat (limited to 'python/vyos/configtree.py')
-rw-r--r--python/vyos/configtree.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/python/vyos/configtree.py b/python/vyos/configtree.py
index 078a8ad0a..9308bdde4 100644
--- a/python/vyos/configtree.py
+++ b/python/vyos/configtree.py
@@ -60,7 +60,7 @@ class ConfigTree(object):
self.__get_error.restype = c_char_p
self.__to_string = self.__lib.to_string
- self.__to_string.argtypes = [c_void_p]
+ self.__to_string.argtypes = [c_void_p, c_bool]
self.__to_string.restype = c_char_p
self.__to_commands = self.__lib.to_commands
@@ -160,8 +160,8 @@ class ConfigTree(object):
def _get_config(self):
return self.__config
- def to_string(self):
- config_string = self.__to_string(self.__config).decode()
+ def to_string(self, ordered_values=False):
+ config_string = self.__to_string(self.__config, ordered_values).decode()
config_string = "{0}\n{1}".format(config_string, self.__version)
return config_string