i am a Maxime, beginner in RobotFramework and I am facing issue.
I am working with Python 3.9 and Robot 3.2.2.
I try to write some code to test a web application. For this I write python Class who use selenium to launch application under a web browser (Chrome).
To test it I need to launch 2 instances of my class.
When I do that with robot, it seems that robot use only the last version of my class (wrong driver)
here my example:
My robot code:
** Settings ***
Library AppUI WITH NAME UI1
Library AppUI WITH NAME UI2
*** Keywords ***
UI1.login login password #In this case Robot use last openned browser UI2 browser
UI2.login login password #This failed because login page is not display he already login …
My python code:
def __init__(self, url) self.url = url self.driver = None def open_application(self): """ Launch application """ self.driver.get(self.url)
If I try to write my test in python everything is working as expected but with Robot, it used the wrong driver (everytime the last one)
Does anyone have an idea about this issue ?