Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. CrawlerSelectorTextSame.php

function CrawlerSelectorTextSame::matches

Parameters

Crawler $crawler:

Overrides Constraint::matches

File

vendor/symfony/dom-crawler/Test/Constraint/CrawlerSelectorTextSame.php, line 33

Class

CrawlerSelectorTextSame

Namespace

Symfony\Component\DomCrawler\Test\Constraint

Code

protected function matches($crawler) : bool {
    $crawler = $crawler->filter($this->selector);
    if (!\count($crawler)) {
        return false;
    }
    return $this->expectedText === trim($crawler->text(null, true));
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal