I am working on a test case in which I need to verify that changing an option in a drop down list changes the styling the page. I am wondering if Webdriver is capable of getting the css document url from an element. I feel as this is the best solution for my test case as I do now know what will change on the page but I do know it will have a different css source from the original page load. Attached is a screenshot of the information I am hoping to extract. Maybe possible with getCssValue() but I am not sure what css property that would be if any.
Asked
Active
Viewed 192 times
0
Buster
- 573
- 1
- 4
- 25
1 Answers
0
<input id="username" name="name" value="selenium">input</input>
You can user element.getAttirbute(""); , in this case if you use driver.findElement(By.Id('username')).getAttribute("value"); It will return selenium.
piet.t
- 11,400
- 21
- 42
- 50
Sudha Velan
- 625
- 8
- 23