diff --git a/tripleo_common/tests/utils/test_config.py b/tripleo_common/tests/utils/test_config.py index c5bd49b58..b04508a50 100644 --- a/tripleo_common/tests/utils/test_config.py +++ b/tripleo_common/tests/utils/test_config.py @@ -180,7 +180,7 @@ class TestConfig(base.TestCase): % step) playbook_tasks = self.config._write_tasks_per_step( self.config.stack_outputs.get('RoleData')[role] - ['upgrade_tasks'], role, filepath, step) + ['upgrade_tasks'], filepath, step) self.assertTrue(os.path.isfile(filepath)) self.assertEqual(expected_tasks[role][step], playbook_tasks) diff --git a/tripleo_common/utils/config.py b/tripleo_common/utils/config.py index 76d3c61de..0a0ca34e4 100644 --- a/tripleo_common/utils/config.py +++ b/tripleo_common/utils/config.py @@ -121,7 +121,7 @@ class Config(object): return os.fdopen( os.open(path, os.O_WRONLY | os.O_CREAT | os.O_TRUNC, 0o600), 'w') - def _write_tasks_per_step(self, tasks, role, filepath, step): + def _write_tasks_per_step(self, tasks, filepath, step): def step_in_task(task, step): whenexpr = task.get('when', None) @@ -268,7 +268,7 @@ class Config(object): for i in range(constants.DEFAULT_STEPS_MAX): filepath = os.path.join(role_path, '%s_step%s.yaml' % (config, i)) - self._write_tasks_per_step(role[config], role_name, + self._write_tasks_per_step(role[config], filepath, i) try: