summaryrefslogtreecommitdiff
path: root/ext/pdo/tests
diff options
context:
space:
mode:
authorDavid Soria Parra <dsp@php.net>2007-12-30 17:51:35 +0000
committerDavid Soria Parra <dsp@php.net>2007-12-30 17:51:35 +0000
commit07487ad0e739e7c7c0db67c9e7a1c7e3e96ed35d (patch)
treef0b0dee3a69a0ab0e9ff4aeb0a21453310d1a2f7 /ext/pdo/tests
parentdddc5682db5c874b13df37279444d1141447f9e7 (diff)
downloadphp-git-07487ad0e739e7c7c0db67c9e7a1c7e3e96ed35d.tar.gz
- Fixed bug #43663 (Extending PDO class with a __call() function doesn't work).
CVS
Diffstat (limited to 'ext/pdo/tests')
-rw-r--r--ext/pdo/tests/bug_43663.phpt23
1 files changed, 23 insertions, 0 deletions
diff --git a/ext/pdo/tests/bug_43663.phpt b/ext/pdo/tests/bug_43663.phpt
new file mode 100644
index 0000000000..25af588bbe
--- /dev/null
+++ b/ext/pdo/tests/bug_43663.phpt
@@ -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