From: Felipe Pena Date: Sun, 19 Jul 2009 18:55:31 +0000 (+0000) Subject: - Fixed bug #48773 (Incorrect error when setting PDO::ATTR_STATEMENT_CLASS with ctor_... X-Git-Tag: php-5.2.11RC1~140 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=995950facb4130cca711e7b6fc5076076b19b76e;p=php - Fixed bug #48773 (Incorrect error when setting PDO::ATTR_STATEMENT_CLASS with ctor_args) [HEAD only] --- diff --git a/ext/pdo_sqlite/tests/bug48773.phpt b/ext/pdo_sqlite/tests/bug48773.phpt new file mode 100644 index 0000000000..b8bdea9185 --- /dev/null +++ b/ext/pdo_sqlite/tests/bug48773.phpt @@ -0,0 +1,34 @@ +--TEST-- +Bug #48773 (Incorrect error when setting PDO::ATTR_STATEMENT_CLASS with ctor_args) +--SKIPIF-- + +--FILE-- +setAttribute(PDO::ATTR_STATEMENT_CLASS, array($this->statementClass, array($this))); + } +} + +$db = new foo('sqlite::memory:', '', ''); +$stmt = $db->query('SELECT 1'); +var_dump($stmt); + +?> +--EXPECTF-- +object(bar)#%d (1) { + [%u|b%"queryString"]=> + %unicode|string%(8) "SELECT 1" +}