no warnings;
use Selenium::Remote::Driver;
my $driver = Selenium::Remote::Driver->new;
$driver->get('https://www.crawler-test.com/');
$driver->find_element_by_xpath('//a[.="text not found"]');
How can I get the above code not to print this warning:
Error while executing command: no such element: Unable to locate element: //a[.="text not found"]
According to the docs, the function issues a "warning" if there is no element found, but having no warnings;
in the script does not suppress it.
How can I suppress this "warning"?