]> granicus.if.org Git - php/commitdiff
Removed old (< 5.3) version of test and cleaned up the actual version.
authorShein Alexey <shein@php.net>
Fri, 2 Sep 2011 17:41:39 +0000 (17:41 +0000)
committerShein Alexey <shein@php.net>
Fri, 2 Sep 2011 17:41:39 +0000 (17:41 +0000)
ext/zip/tests/bug38943.inc [deleted file]
ext/zip/tests/bug38943.phpt
ext/zip/tests/bug38943_2.phpt [deleted file]

diff --git a/ext/zip/tests/bug38943.inc b/ext/zip/tests/bug38943.inc
deleted file mode 100644 (file)
index a6f45e8..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-<?php
-class myZip extends ZipArchive {
-       private $test = 0;
-       public $testp = 1;
-       private $testarray = array();
-
-       public function __construct() {
-               $this->testarray[] = 1;
-               var_dump($this->testarray);
-       }
-}
-
-$z = new myZip;
-$z->testp = "foobar";
-var_dump($z);
-
index 02985848dc2e32521500abc602b2101c9b619c81..c5e22847192ff73d64c2ef7540036636b092529f 100644 (file)
@@ -1,14 +1,26 @@
 --TEST--
-#38943, properties in extended class cannot be set (< 5.3)
+#38943, properties in extended class cannot be set (5.3+)
 --SKIPIF--
 <?php
-/* $Id$ */
 if(!extension_loaded('zip')) die('skip');
-if (!defined('PHP_VERSION_MAJOR')) die('skip');
 ?>
 --FILE--
 <?php
-include dirname(__FILE__) . '/bug38943.inc';
+class myZip extends ZipArchive {
+       private $test = 0;
+       public $testp = 1;
+       private $testarray = array();
+
+       public function __construct() {
+               $this->testarray[] = 1;
+               var_dump($this->testarray);
+       }
+}
+
+$z = new myZip;
+$z->testp = "foobar";
+var_dump($z);
+
 ?>
 --EXPECTF--
 array(1) {
@@ -16,11 +28,11 @@ array(1) {
   int(1)
 }
 object(myZip)#1 (%d) {
-  ["test:private"]=>
+  ["test":"myZip":private]=>
   int(0)
   ["testp"]=>
   string(6) "foobar"
-  ["testarray:private"]=>
+  ["testarray":"myZip":private]=>
   array(1) {
     [0]=>
     int(1)
diff --git a/ext/zip/tests/bug38943_2.phpt b/ext/zip/tests/bug38943_2.phpt
deleted file mode 100644 (file)
index 8672d9d..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
---TEST--
-#38943, properties in extended class cannot be set (5.3)
---SKIPIF--
-<?php
-/* $Id$ */
-if(!extension_loaded('zip')) die('skip');
-if (version_compare(PHP_VERSION, "5.3", "<")) die('skip test for5.3+ only');
-?>
---FILE--
-<?php
-include 'bug38943.inc';
-?>
---EXPECTF--
-array(1) {
-  [0]=>
-  int(1)
-}
-object(myZip)#1 (%d) {
-  ["test":"myZip":private]=>
-  int(0)
-  ["testp"]=>
-  string(6) "foobar"
-  ["testarray":"myZip":private]=>
-  array(1) {
-    [0]=>
-    int(1)
-  }
-  ["status"]=>
-  int(0)
-  ["statusSys"]=>
-  int(0)
-  ["numFiles"]=>
-  int(0)
-  ["filename"]=>
-  string(0) ""
-  ["comment"]=>
-  string(0) ""
-}