I'm a newbie on ruby language... Currently, I am using POM (page objects model) with Selenium webdriver.
This is my trouble:
As I'm using selenium with POM, I have 3 classes (register.br, login.br and log_out.br) and in my main class I'm calling the objects and methods for executing the Test (test.br)
How each class has
@driver=Selenium::WebDriver.for :firefoxthe problem is when I execute my main class (test.br), every class called with this ' @driver` open a new browser...
My question is: How can I do for instantiating each class my selenium webdriver, realizing all the process just in one browser (the process is register, login and logout).
Currently, the process is completed but in three firefox browsers and I need just all the process in the same browser.
PD: I used
$driver=Selenium::WebDriver.for :firefox with the
$ in the test.br class and called in every class with the
require relative but doesn't work