1.20.x unicode.test UnicodeUnitTest::helperTestStrLen()

File

modules/simpletest/tests/unicode.test, line 109
Various unicode handling tests.

Class

UnicodeUnitTest
Test unicode handling features implemented in unicode.inc.

Code

function helperTestStrLen() {
  $testcase = array(
    'tHe QUIcK bRoWn' => 15,
    'ÜBER-åwesome' => 12,
  );

  foreach ($testcase as $input => $output) {
    $this->assertEqual(backdrop_strlen($input), $output, format_string('%input length is %output', array('%input' => $input, '%output' => $output)));
  }
}