endsWith() public static method

Assert that string ends with a sequence of chars.
public static endsWith ( mixed $string, string $needle, string | null $message = null, string | null $propertyPath = null, string $encoding = 'utf8' ) : boolean
$string mixed
$needle string
$message string | null
$propertyPath string | null
$encoding string
return boolean
Esempio n. 1
0
 public function testValidEndsWith()
 {
     Assertion::endsWith("foo", "foo");
     Assertion::endsWith("sonderbar", "bar");
     Assertion::endsWith("opp", "p");
     Assertion::endsWith("foo址", "址");
 }
 /**
  * @Then the log messages should be shown
  */
 public function theLogMessagesShouldBeShown()
 {
     list($line0, $line1) = $this->data['output'];
     Assertion::startsWith($line0, 'purging database');
     Assertion::endsWith($line1, RoleFixture::class);
 }