summaryrefslogtreecommitdiff
path: root/ext/pdo_mysql
diff options
context:
space:
mode:
authorMarcus Boerger <helly@php.net>2005-02-21 18:55:51 +0000
committerMarcus Boerger <helly@php.net>2005-02-21 18:55:51 +0000
commitab8f1f316b04b24d98830707ba3b192618004a18 (patch)
treed21249283e423a04d1792333ee368393ad85902c /ext/pdo_mysql
parent74b1cee57fcca11edc8e0377b1a1b1f7f61313b1 (diff)
downloadphp-git-ab8f1f316b04b24d98830707ba3b192618004a18.tar.gz
- Add new test
Diffstat (limited to 'ext/pdo_mysql')
-rwxr-xr-xext/pdo_mysql/tests/pdo_mysql_010.phpt76
1 files changed, 76 insertions, 0 deletions
diff --git a/ext/pdo_mysql/tests/pdo_mysql_010.phpt b/ext/pdo_mysql/tests/pdo_mysql_010.phpt
new file mode 100755
index 0000000000..03be77c991
--- /dev/null
+++ b/ext/pdo_mysql/tests/pdo_mysql_010.phpt
@@ -0,0 +1,76 @@
+--TEST--
+PDO-MySQL: PDO_FETCH_(CLASSTYPE and GROUP/UNIQUE)
+--SKIPIF--
+<?php # vim:ft=php
+require_once('skipif.inc'); ?>
+--FILE--
+<?php
+
+require_once('connection.inc');
+require_once('prepare.inc');
+
+require_once($PDO_TESTS . 'pdo_010.inc');
+
+?>
+===DONE===
+<?php exit(0); ?>
+--EXPECTF--
+Test1::__construct()
+Test2::__construct()
+Test3::__construct()
+array(2) {
+ ["Group1"]=>
+ array(2) {
+ [0]=>
+ object(stdClass)#%d (2) {
+ ["id"]=>
+ string(1) "1"
+ ["val"]=>
+ string(1) "A"
+ }
+ [1]=>
+ object(Test1)#%d (2) {
+ ["id"]=>
+ string(1) "2"
+ ["val"]=>
+ string(1) "B"
+ }
+ }
+ ["Group2"]=>
+ array(2) {
+ [0]=>
+ object(Test2)#%d (2) {
+ ["id"]=>
+ string(1) "3"
+ ["val"]=>
+ string(1) "C"
+ }
+ [1]=>
+ object(Test3)#%d (2) {
+ ["id"]=>
+ string(1) "4"
+ ["val"]=>
+ string(1) "D"
+ }
+ }
+}
+Test1::__construct()
+Test2::__construct()
+Test3::__construct()
+array(2) {
+ ["Group1"]=>
+ object(Test1)#%d (2) {
+ ["id"]=>
+ string(1) "2"
+ ["val"]=>
+ string(1) "B"
+ }
+ ["Group2"]=>
+ object(Test3)#%d (2) {
+ ["id"]=>
+ string(1) "4"
+ ["val"]=>
+ string(1) "D"
+ }
+}
+===DONE===