Understanding the x-path is crucial, such as < img id="" src="/A/A/B.png" style="">
My task involves identifying the color of the image, but unfortunately, the style attribute does not provide any information about color. It only includes details about height and width.
I believe that the fill attribute would be present in the src path. However, how can I navigate to it?
One potential solution that comes to mind is:
String css = driver.findElement(By.Xpath("..blah../img").getCSSValue("background-color");
Despite this approach, I am still receiving 'transparent' as my answer. How should I proceed from here?