diff options
| author | Marcus Boerger <helly@php.net> | 2005-02-23 01:13:13 +0000 |
|---|---|---|
| committer | Marcus Boerger <helly@php.net> | 2005-02-23 01:13:13 +0000 |
| commit | 3f1738f96da9c66ae842ff39a88f0ea938e02ed3 (patch) | |
| tree | 0deb8cabbbb41628a421fd112f8d2b2fdba7b113 /ext | |
| parent | 72c1baa9d8491ffa89095f109437be471b89dfa9 (diff) | |
| download | php-git-3f1738f96da9c66ae842ff39a88f0ea938e02ed3.tar.gz | |
- Add new tests
Diffstat (limited to 'ext')
| -rwxr-xr-x | ext/pdo_mysql/tests/pdo_mysql_014.phpt | 58 | ||||
| -rwxr-xr-x | ext/pdo_pgsql/tests/pdo_pgsql_014.phpt | 58 | ||||
| -rwxr-xr-x | ext/pdo_sqlite/tests/pdo_sqlite_014.phpt | 58 |
3 files changed, 174 insertions, 0 deletions
diff --git a/ext/pdo_mysql/tests/pdo_mysql_014.phpt b/ext/pdo_mysql/tests/pdo_mysql_014.phpt new file mode 100755 index 0000000000..493a1f740c --- /dev/null +++ b/ext/pdo_mysql/tests/pdo_mysql_014.phpt @@ -0,0 +1,58 @@ +--TEST-- +PDO_MySQL: PDOStatement and SPL Iterators +--SKIPIF-- +<?php # vim:ft=php +require_once('skipif.inc'); +if (!extension_loaded('SPL')) die('skip SPL not available'); +?> +--FILE-- +<?php + +require_once('connection.inc'); +require_once('prepare.inc'); + +require_once($PDO_TESTS . 'pdo_014.inc'); + +?> +===DONE=== +<?php exit(0); ?> +--EXPECTF-- +Test::__construct(WOW) +object(Test)#4 (2) { + ["val"]=> + string(1) "A" + ["grp"]=> + string(6) "Group1" +} +Test::__construct(WOW) +object(Test)#6 (2) { + ["val"]=> + string(1) "B" + ["grp"]=> + string(6) "Group2" +} +NULL +bool(false) +PDOStatementAggregate::__construct +PDOStatementAggregate::getIterator +array(4) { + ["val"]=> + string(1) "A" + [0]=> + string(1) "A" + ["grp"]=> + string(6) "Group1" + [1]=> + string(6) "Group1" +} +array(4) { + ["val"]=> + string(1) "B" + [0]=> + string(1) "B" + ["grp"]=> + string(6) "Group2" + [1]=> + string(6) "Group2" +} +===DONE=== diff --git a/ext/pdo_pgsql/tests/pdo_pgsql_014.phpt b/ext/pdo_pgsql/tests/pdo_pgsql_014.phpt new file mode 100755 index 0000000000..9a622d3b7e --- /dev/null +++ b/ext/pdo_pgsql/tests/pdo_pgsql_014.phpt @@ -0,0 +1,58 @@ +--TEST-- +PDO_PGSQL: PDOStatement and SPL Iterators +--SKIPIF-- +<?php # vim:ft=php +require_once('skipif.inc'); +if (!extension_loaded('SPL')) die('skip SPL not available'); +?> +--FILE-- +<?php + +require_once('connection.inc'); +require_once('prepare.inc'); + +require_once($PDO_TESTS . 'pdo_014.inc'); + +?> +===DONE=== +<?php exit(0); ?> +--EXPECTF-- +Test::__construct(WOW) +object(Test)#4 (2) { + ["val"]=> + string(1) "A" + ["grp"]=> + string(6) "Group1" +} +Test::__construct(WOW) +object(Test)#6 (2) { + ["val"]=> + string(1) "B" + ["grp"]=> + string(6) "Group2" +} +NULL +bool(false) +PDOStatementAggregate::__construct +PDOStatementAggregate::getIterator +array(4) { + ["val"]=> + string(1) "A" + [0]=> + string(1) "A" + ["grp"]=> + string(6) "Group1" + [1]=> + string(6) "Group1" +} +array(4) { + ["val"]=> + string(1) "B" + [0]=> + string(1) "B" + ["grp"]=> + string(6) "Group2" + [1]=> + string(6) "Group2" +} +===DONE=== diff --git a/ext/pdo_sqlite/tests/pdo_sqlite_014.phpt b/ext/pdo_sqlite/tests/pdo_sqlite_014.phpt new file mode 100755 index 0000000000..193019c948 --- /dev/null +++ b/ext/pdo_sqlite/tests/pdo_sqlite_014.phpt @@ -0,0 +1,58 @@ +--TEST-- +PDO_SQLite: PDOStatement and SPL Iterators +--SKIPIF-- +<?php # vim:ft=php +require_once('skipif.inc'); +if (!extension_loaded('SPL')) die('skip SPL not available'); +?> +--FILE-- +<?php + +require_once('connection.inc'); +require_once('prepare.inc'); + +require_once($PDO_TESTS . 'pdo_014.inc'); + +?> +===DONE=== +<?php exit(0); ?> +--EXPECTF-- +Test::__construct(WOW) +object(Test)#4 (2) { + ["val"]=> + string(1) "A" + ["grp"]=> + string(6) "Group1" +} +Test::__construct(WOW) +object(Test)#6 (2) { + ["val"]=> + string(1) "B" + ["grp"]=> + string(6) "Group2" +} +NULL +bool(false) +PDOStatementAggregate::__construct +PDOStatementAggregate::getIterator +array(4) { + ["val"]=> + string(1) "A" + [0]=> + string(1) "A" + ["grp"]=> + string(6) "Group1" + [1]=> + string(6) "Group1" +} +array(4) { + ["val"]=> + string(1) "B" + [0]=> + string(1) "B" + ["grp"]=> + string(6) "Group2" + [1]=> + string(6) "Group2" +} +===DONE=== |
