I have an application where users can create lists...once they create a list it will show up in a table on their homepage of the app. Only lists the user creates should display in the "created by" column of the table.
I'm trying to have the test fail and print if the expected name is not found.
users_names = context.browser.find_elements_by_xpath("//tr//td[7]")
expected_name = "%s" % name
for name in expected_name:
if name.text != expected_name:
print("Failed\n", users_names)