From 3a7aee527ec63a57d3bb52650c7adb955e43229e Mon Sep 17 00:00:00 2001 From: Thomas Herve Date: Wed, 1 Feb 2017 13:58:13 +0100 Subject: [PATCH] Fix config file management in tests This fixes some tests that tried to set options on python3. Change-Id: Ib2cd36b318b4f8487045c5142fa3c200db61bc79 --- heat_integrationtests/functional/test_reload_on_sighup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/heat_integrationtests/functional/test_reload_on_sighup.py b/heat_integrationtests/functional/test_reload_on_sighup.py index d6465811ad..252cec87b6 100644 --- a/heat_integrationtests/functional/test_reload_on_sighup.py +++ b/heat_integrationtests/functional/test_reload_on_sighup.py @@ -49,7 +49,7 @@ class ReloadOnSighupTest(functional_base.FunctionalTestsBase): while True: config.read(self.config_file) try: - config.set(service, key, value) + config.set(service, key, str(value)) except configparser.NoSectionError: if retries_count <= 0: raise @@ -58,7 +58,7 @@ class ReloadOnSighupTest(functional_base.FunctionalTestsBase): else: break - with open(self.config_file, 'wb') as f: + with open(self.config_file, 'w') as f: config.write(f) def _get_config_value(self, service, key):