]> granicus.if.org Git - php/commitdiff
- Added tests for BC breaking changes.
authorDerick Rethans <derick@php.net>
Fri, 12 May 2006 10:02:13 +0000 (10:02 +0000)
committerDerick Rethans <derick@php.net>
Fri, 12 May 2006 10:02:13 +0000 (10:02 +0000)
Zend/tests/abstract-static.phpt [new file with mode: 0644]
Zend/tests/object-null.phpt [new file with mode: 0644]

diff --git a/Zend/tests/abstract-static.phpt b/Zend/tests/abstract-static.phpt
new file mode 100644 (file)
index 0000000..9db88fc
--- /dev/null
@@ -0,0 +1,24 @@
+--TEST--
+Test for abstract static classes
+--FILE--
+<?php
+abstract class ezcDbHandler extends PDO
+{
+    public function __construct( $dbParams, $dsn )
+    {
+        $user          = null;
+        $pass          = null;
+        $driverOptions = null;
+    }
+
+    abstract static public function getName();
+
+    static public function hasFeature( $feature )
+    {
+        return false;
+    }
+}
+?>
+DONE
+--EXPECT--
+DONE
diff --git a/Zend/tests/object-null.phpt b/Zend/tests/object-null.phpt
new file mode 100644 (file)
index 0000000..650178c
--- /dev/null
@@ -0,0 +1,21 @@
+--TEST--
+Test whether an object is NULL or not.
+--FILE--
+<?php
+
+class Bla
+{
+}
+
+$b = new Bla;
+
+var_dump($b != null);
+var_dump($b == null);
+var_dump($b !== null);
+var_dump($b === null);
+?>
+--EXPECT--
+bool(true)
+bool(false)
+bool(true)
+bool(false)