diff options
author | 2022-09-23 10:48:26 +0200 | |
---|---|---|
committer | 2022-09-23 13:18:25 +0200 | |
commit | 506e825a31f0826bbe1fa7bc6d28addd7b0ee6a4 (patch) | |
tree | da78998bb0955895d53a8ca08cc62aa3e8c09c2d /xtesting/core/robotframework.py | |
parent | 0e9f1fb341392881074b2d11830cf42a2bd2abf4 (diff) |
Make robot driver even more generic
It allows setting any option via testcases.yaml
Change-Id: I8cb5ead037a65f962c3ba1a14729b52195e95483
Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
(cherry picked from commit 25c7404b8d2a8f36170f6067c97915ddb6128bfd)
Diffstat (limited to 'xtesting/core/robotframework.py')
-rw-r--r-- | xtesting/core/robotframework.py | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/xtesting/core/robotframework.py b/xtesting/core/robotframework.py index 2952de60..92b75930 100644 --- a/xtesting/core/robotframework.py +++ b/xtesting/core/robotframework.py @@ -106,10 +106,7 @@ class RobotFramework(testcase.TestCase): EX_RUN_ERROR otherwise. """ try: - suites = kwargs["suites"] - variable = kwargs.get("variable", []) - variablefile = kwargs.get("variablefile", []) - include = kwargs.get("include", []) + suites = kwargs.pop("suites") except KeyError: self.__logger.exception("Mandatory args were not passed") return self.EX_RUN_ERROR @@ -120,9 +117,11 @@ class RobotFramework(testcase.TestCase): self.__logger.exception("Cannot create %s", self.res_dir) return self.EX_RUN_ERROR stream = StringIO() - robot.run(*suites, variable=variable, variablefile=variablefile, - include=include, output=self.xml_file, log='NONE', - report='NONE', stdout=stream) + kwargs["output"] = self.xml_file + kwargs["log"] = "NONE" + kwargs["report"] = "NONE" + kwargs["stdout"] = stream + robot.run(*suites, **kwargs) self.__logger.info("\n%s", stream.getvalue()) try: self.parse_results() |