Ask a Question

How to verify hyperlinks

ḥari
Frequent Contributor

How to verify hyperlinks

Hi

 

Here I have attached image there "Test complete samples" are href links. How can I verify while mouse Hover to that element it shows underline and color change??

 

Any inbuilt methods available in TC!!!

 

ari_0-1675766008732.png

 

 

Thanks team!

2 REPLIES 2
rraghvani
Champion Level 3

Default style links are rendered by the browser. However, if the website is using CSS for styling links then you should be able to get the attributes, see Getting CSS Attributes.

 

You can use getAttribute('href') method to return the URL.

ḥari
Frequent Contributor

To get the font color can I use like this

 

var color = page.FindElement("xpath");

  Log.Message(color.style.fontcolor);

cancel
Showing results for 
Search instead for 
Did you mean: