Skip to content

Commit

Permalink
Make ExceptionMessage strict
Browse files Browse the repository at this point in the history
  • Loading branch information
keradus authored and sebastianbergmann committed Oct 9, 2018
1 parent 488da46 commit 8f3e96f
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/Framework/Constraint/ExceptionMessage.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,7 @@ public function __construct($expected)
*/
protected function matches($other)
{
if ($this->expectedMessage === '') {
return $other->getMessage() === '';
}

return \strpos($other->getMessage(), $this->expectedMessage) !== false;
return $other->getMessage() === $this->expectedMessage;
}

/**
Expand Down

0 comments on commit 8f3e96f

Please sign in to comment.