We need the list of virtual machines in the virtual environment to parse
the recipe, but we can create the list of used machines only when we
have a recipe. So we need to split these function.
Signed-off-by: Jonatan Schlag <jonatan.schlag@ipfire.org>
settings_file=args.settings,
cmd_settings=settings)
currenttest.read_settings()
+ currenttest.virtual_environ_setup_stage_1()
currenttest.load_recipe()
- currenttest.virtual_environ_setup()
+ currenttest.virtual_environ_setup_stage_2()
except RecipeExeption as e:
logger.exception(e)
return 2
self.log.debug("{}: {}".format(key, self.settings[key]))
- def virtual_environ_setup(self):
+ def virtual_environ_setup_stage_1(self):
self.virtual_environ = virtual_environ.VirtualEnviron(self.settings["virtual_environ_path"])
self.virtual_networks = self.virtual_environ.get_networks()
self.virtual_machines = self.virtual_environ.get_machines()
+ def virtual_environ_setup_stage_2(self):
# built up which machines which are used in our recipe
used_machines = []