Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 298221

Default message for linkNotExists and linkByHrefNotExists is wrong

$
0
0

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.


Viewing all articles
Browse latest Browse all 298221

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>