Answer the question
In order to leave comments, you need to log in
How to fill in the login and password fields on the updated page (autotest)?
I'm just getting started with autotesting.
I am writing an autotest (I use selenium and c#) for this site onliner.by
First you need to go through authorization, using xPath I find the "Login" button
and click - everything is in order.
Then the page is updated, fields for entering a login and password appear, but the page address remains the same ( http://onliner.by).
I also copied the Xpaths of these elements, but this code does not work:
driver.FindElement(By.XPath("//*[@id='auth-container__forms']/div/div[2]/form/div[1]/div[1]/input")).SendKeys("user");
driver.FindElement(By.XPath("//*[@id='auth-container__forms']/div/div[2]/form/div[1]/div[2]/input")).SendKeys("password");
driver.FindElement(By.XPath("//*[@id='auth-container__forms']/div/div[2]/form/div[3]/div/button")).Click();
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question