Skip to content

Commit

Permalink
bug #35899 [DomCrawler] prevent deprecation being triggered from asse…
Browse files Browse the repository at this point in the history
…rtion (xabbuh)

This PR was merged into the 4.4 branch.

Discussion
----------

[DomCrawler] prevent deprecation being triggered from assertion

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #35889
| License       | MIT
| Doc PR        |

Commits
-------

b01a10c prevent deprecation being triggered from assertion
  • Loading branch information
fabpot committed Mar 2, 2020
2 parents 2bd76fa + b01a10c commit 0936a4e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Expand Up @@ -45,7 +45,7 @@ protected function matches($crawler): bool
return false;
}

return false !== mb_strpos($crawler->text(), $this->expectedText);
return false !== mb_strpos($crawler->text(null, false), $this->expectedText);
}

/**
Expand Down
Expand Up @@ -45,7 +45,7 @@ protected function matches($crawler): bool
return false;
}

return $this->expectedText === trim($crawler->text());
return $this->expectedText === trim($crawler->text(null, false));
}

/**
Expand Down

0 comments on commit 0936a4e

Please sign in to comment.