selenium ide: how to verify value from external css file -


myi know if possible check values external css file selenium ide?

my html:

<div id="myblock"> 

my css style:

#myblock {     background: none repeat scroll 0 0 #ffffff;     margin: 0;     padding: 0; } 

i need verify background-color. tryed use verifyattribute //[@id="myblock"]@background or //[@id="myblock"]@style, attribute not found. correct way it?

a combination of storeeval , javascript's getcomputedstyle has worked in past. of course, you'll have enable javascript in browser!

the below, when run in selenium ide against html, should return rgb code of hex code.

<tr>     <td>storeeval</td>     <td>window.document.defaultview.getcomputedstyle(window.document.getelementsbyclassname('myblock')[0]).getpropertyvalue('background-color')</td>     <td>storedcolorvariable</td> </tr> 

the variable storedcolorvariable contain background color rgb(255, 255, 255).


Comments

Popular posts from this blog

matlab - "Contour not rendered for non-finite ZData" -

delphi - Indy UDP Read Contents of Adata -

javascript - Any ideas when Firefox is likely to implement lengthAdjust and textLength? -