]> granicus.if.org Git - php/commitdiff
Test for bug 43663
authorDavid Soria Parra <dsp@php.net>
Sun, 30 Dec 2007 17:48:24 +0000 (17:48 +0000)
committerDavid Soria Parra <dsp@php.net>
Sun, 30 Dec 2007 17:48:24 +0000 (17:48 +0000)
ext/pdo/tests/bug_43663.phpt [new file with mode: 0644]

diff --git a/ext/pdo/tests/bug_43663.phpt b/ext/pdo/tests/bug_43663.phpt
new file mode 100644 (file)
index 0000000..25af588
--- /dev/null
@@ -0,0 +1,23 @@
+--TEST--
+PDO Common: Bug #43663 (__call on classes derived from PDO)
+--FILE--
+--SKIPIF--
+<?php # vim:ft=php
+if (!extension_loaded('pdo')) die('skip');
+?>
+--FILE--
+<?php
+class test extends PDO{
+    function __call($name, array $args) {
+        echo "Called $name in ".__CLASS__."\n";
+    }
+    function foo() {
+        echo "Called foo in ".__CLASS__."\n";
+    }
+}
+$a = new test('sqlite::memory:');
+$a->foo();
+$a->bar();
+--EXPECT--
+Called foo in test
+Called bar in test