You are here

public function UnicodeTest::testLcfirst in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/tests/Drupal/Tests/Component/Utility/UnicodeTest.php \Drupal\Tests\Component\Utility\UnicodeTest::testLcfirst()

Tests multibyte lcfirst.

@dataProvider providerLcfirst @covers ::lcfirst

File

core/tests/Drupal/Tests/Component/Utility/UnicodeTest.php, line 207
Contains \Drupal\Tests\Component\Utility\UnicodeTest.

Class

UnicodeTest
Test unicode handling features implemented in Unicode component.

Namespace

Drupal\Tests\Component\Utility

Code

public function testLcfirst($text, $expected, $multibyte = FALSE) {
  $status = $multibyte ? Unicode::STATUS_MULTIBYTE : Unicode::STATUS_SINGLEBYTE;
  Unicode::setStatus($status);
  $this
    ->assertEquals($expected, Unicode::lcfirst($text));
}