I'm using Selenium IDE and need to identify when an item of text has the css 'font-weight:bold' applied to it (with 'verifyAttribute')
Using the following CSS locator:
css=body.home.es ul#languages li:nth-child(2) a.selected
Selenium can find the item. I now need to dive into the CSS and confirm that font-weight:bold has been applied. The CSS of the site I am testing is:
ul.language li a.selected {
color: #FFFFFF;
font-weight: bold;
I've drawn a blank; can it be achieved this way, do I need to dive into DOM locators? Or is Java the solution? (which for me isn't that easy)
Thanks in advance for your assistance!
Since it looks like you need the computed style, I think you you need to use javascript.
You can do this with the following step in Selenium IDE:
Note that the value of 700 is a font-weight of bold.
This solution was tested in Firefox. If you are using IE, it'll be slightly different - see here.