iliaa                                    Mon, 25 Jan 2010 13:08:43 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=293974

Log:
Added test case for bug #44827

Bug: http://bugs.php.net/44827 (Closed) define('::') can be defined
      
Changed paths:
    A   php/php-src/branches/PHP_5_2/Zend/tests/bug44827.phpt
    A   php/php-src/branches/PHP_5_3/Zend/tests/bug44827.phpt
    A   php/php-src/trunk/Zend/tests/bug44827.phpt

Added: php/php-src/branches/PHP_5_2/Zend/tests/bug44827.phpt
===================================================================
--- php/php-src/branches/PHP_5_2/Zend/tests/bug44827.phpt                       
        (rev 0)
+++ php/php-src/branches/PHP_5_2/Zend/tests/bug44827.phpt       2010-01-25 
13:08:43 UTC (rev 293974)
@@ -0,0 +1,11 @@
+--TEST--
+Bug #44827 (define() allows :: in constant names)
+--FILE--
+<?php
+define('foo::bar', 1);
+define('::', 1);
+?>
+--EXPECTF--
+Warning: Class constants cannot be defined or redefined in %sbug44827.php on 
line %d
+
+Warning: Class constants cannot be defined or redefined in %sbug44827.php on 
line %d

Added: php/php-src/branches/PHP_5_3/Zend/tests/bug44827.phpt
===================================================================
--- php/php-src/branches/PHP_5_3/Zend/tests/bug44827.phpt                       
        (rev 0)
+++ php/php-src/branches/PHP_5_3/Zend/tests/bug44827.phpt       2010-01-25 
13:08:43 UTC (rev 293974)
@@ -0,0 +1,11 @@
+--TEST--
+Bug #44827 (define() allows :: in constant names)
+--FILE--
+<?php
+define('foo::bar', 1);
+define('::', 1);
+?>
+--EXPECTF--
+Warning: Class constants cannot be defined or redefined in %sbug44827.php on 
line %d
+
+Warning: Class constants cannot be defined or redefined in %sbug44827.php on 
line %d

Added: php/php-src/trunk/Zend/tests/bug44827.phpt
===================================================================
--- php/php-src/trunk/Zend/tests/bug44827.phpt                          (rev 0)
+++ php/php-src/trunk/Zend/tests/bug44827.phpt  2010-01-25 13:08:43 UTC (rev 
293974)
@@ -0,0 +1,11 @@
+--TEST--
+Bug #44827 (define() allows :: in constant names)
+--FILE--
+<?php
+define('foo::bar', 1);
+define('::', 1);
+?>
+--EXPECTF--
+Warning: Class constants cannot be defined or redefined in %sbug44827.php on 
line %d
+
+Warning: Class constants cannot be defined or redefined in %sbug44827.php on 
line %d

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to