com php-src: add test: Zend/tests/bug18556.phpt

From: Date: Sat, 14 Jul 2012 21:50:50 +0000
Subject: com php-src: add test: Zend/tests/bug18556.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-69588@lists.php.net to get a copy of this message
Commit: c164e6b5a37b668a016846060d8e039d6af32ae5 Author: Stanislav Malyshev <stas@php.net> Tue, 10 Jul 2012 21:47:56 -0700 Parents: 582514d4c7b216dbdc7a8429962cf3e5776206f0 Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=c164e6b5a37b668a016846060d8e039d6af32ae5 Log: add test Changed paths: A Zend/tests/bug18556.phpt Diff: diff --git a/Zend/tests/bug18556.phpt b/Zend/tests/bug18556.phpt new file mode 100644 index 0000000..a9fbb59 --- /dev/null +++ b/Zend/tests/bug18556.phpt @@ -0,0 +1,36 @@ +--TEST-- +Bug #18556 (Setting locale to 'tr_TR' lowercases class names) +--FILE-- +<?php +$g_lang = 'tr_TR'; +putenv("LANG=$g_lang"); +setlocale(LC_ALL, $g_lang); + +class InfoBlob { + var $foo; + function InfoBlob() { + $this->foo = "Foo"; + } +} + +echo "Instantiating an infoBlob with a lowercase i\n"; +$foobar = new infoBlob(); +echo $foobar->foo; +echo "\nInstantiating an InfoBlob with an uppercase I\n"; +$foobar = new InfoBlob(); +echo $foobar->foo; +echo "\n"; +setlocale(LC_ALL, "tr_TR.utf8"); +foreach(get_declared_classes() as $class) +{ + if(!class_exists($class)) + echo "$class No Longer Exists!\n"; +} +echo "Done.\n"; +?> +--EXPECT-- +Instantiating an infoBlob with a lowercase i +Foo +Instantiating an InfoBlob with an uppercase I +Foo +Done.

« previous php.cvs (#69588) next »