diff options
Diffstat (limited to 'ext/iconv/tests/iconv_strlen.phpt')
| -rw-r--r-- | ext/iconv/tests/iconv_strlen.phpt | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/ext/iconv/tests/iconv_strlen.phpt b/ext/iconv/tests/iconv_strlen.phpt new file mode 100644 index 0000000..2c815f4 --- /dev/null +++ b/ext/iconv/tests/iconv_strlen.phpt @@ -0,0 +1,19 @@ +--TEST-- +iconv_strlen() +--SKIPIF-- +<?php extension_loaded('iconv') or die('skip iconv extension is not available'); ?> +--FILE-- +<?php +function foo($str, $charset) { + var_dump(strlen($str)); + var_dump(iconv_strlen($str, $charset)); +} + +foo("abc", "ASCII"); +foo("ÆüËܸì EUC-JP", "EUC-JP"); +?> +--EXPECT-- +int(3) +int(3) +int(13) +int(10) |
