I'm trying to use selenium webdriver
to assert a
logo.svg == context.driver.find_element_by_xpath("//img[@src='../logo.svg']"
on Python3.
So, when I'm running the testcase I get:
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.NoSuchElementException: Message: no such element: Unable to locate element: {"method":"xpath","selector":"//img[@src='../logo.svg']"}
Snapshot of the HTML:
I been trying to "find" this particular image on a header with no success. Can anyone help me?
#---- reviwing the issue, logo_company = logo.svg is a string and context.driver.find_element_by..... it's the imagin object. I thinking how can i compare string == string or, maybe, the file.svg == context.driver that return file.svg something like that?