Problem/Motivation
In Drupal\Tests\WebAssert
, linkNotExists() and linkByHrefNotExists() default message are same as respectively linkExists() and linkByHrefExists().
public function linkNotExists($label, $message = '') {
$message = ($message ? $message : strtr('Link with label %label found.', ['%label' => $label]));
public function linkByHrefExists($href, $index = 0, $message = '') {
$xpath = $this->buildXPathQuery('//a[contains(@href, :href)]', [':href' => $href]);
$message = ($message ? $message : strtr('Link containing href %href found.', ['%href' => $href]));
It should be more explicit that string should not be found.