config-download remove role arg from _write_tasks_per_step()

This arg has never been used, let's just remove it.

Change-Id: I2781cae14663094d531ad70c3d412b3153b46612
(cherry picked from commit d9811e94ea)
(cherry picked from commit d31c419d7e)
This commit is contained in:
Emilien Macchi 2020-07-23 14:23:15 -04:00
parent 96886e8c6b
commit 19efd014ee
2 changed files with 3 additions and 3 deletions

View File

@ -171,7 +171,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)

View File

@ -115,7 +115,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)
@ -262,7 +262,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: