Re: com php-src: Apply pgsql notice test fixes to PHP-5.5: ext/pgsql/tests/09notice.phpt ext/pgsql/tests/80_bug32223.phpt
ext/pgsql/tests/80_bug32223b.phpt
| From: | Yasuo Ohgaki | Date: | Fri, 23 Aug 2013 00:41:42 +0000 |
| Subject: | Re: com php-src: Apply pgsql notice test fixes to PHP-5.5: ext/pgsql/tests/09notice.phpt ext/pgsql/tests/80_bug32223.phpt ext/pgsql/tests/80_bug32223b.phpt |
||
| References: | 1 | Groups: | php.cvs |
| Request: | Send a blank email to php-cvs+get-73082@lists.php.net to get a copy of this message | ||
Thank you for back porting :)
--
Yasuo Ohgaki
yohgaki@ohgaki.net
On Thu, Aug 22, 2013 at 9:02 PM, Nikita Popov <nikic@php.net> wrote:
> Commit: c0d99fd76a37785d357ffe7a0fee8715108d3dd5
> Author: Nikita Popov <nikic@php.net> Thu, 22 Aug 2013 14:02:55
> +0200
> Parents: 592677d810feba294c962a1b0191adeea08b6d46
> Branches: PHP-5.5 master
>
> Link:
>
> http://git.php.net/?p=php-src.git;a=commitdiff;h=c0d99fd76a37785d357ffe7a0fee8715108d3dd5
>
> Log:
> Apply pgsql notice test fixes to PHP-5.5
>
> Changed paths:
> M ext/pgsql/tests/09notice.phpt
> M ext/pgsql/tests/80_bug32223.phpt
> M ext/pgsql/tests/80_bug32223b.phpt
>
>
> Diff:
> diff --git a/ext/pgsql/tests/09notice.phpt b/ext/pgsql/tests/09notice.phpt
> index 67ef262..db67101 100644
> --- a/ext/pgsql/tests/09notice.phpt
> +++ b/ext/pgsql/tests/09notice.phpt
> @@ -20,6 +20,9 @@ $db = pg_connect($conn_str);
>
> _set_lc_messages();
>
> +$res = pg_query($db, 'SET client_min_messages TO NOTICE;');
> +var_dump($res);
> +
> pg_query($db, "BEGIN;");
> pg_query($db, "BEGIN;");
>
> @@ -33,6 +36,8 @@ echo "pg_last_notice() is Ok\n";
>
> ?>
> --EXPECTF--
> +resource(%d) of type (pgsql result)
> +
> Notice: pg_query(): %s already a transaction in progress in %s on line %d
> %s already a transaction in progress
> pg_last_notice() is Ok
> diff --git a/ext/pgsql/tests/80_bug32223.phpt
> b/ext/pgsql/tests/80_bug32223.phpt
> index cad5fb3..b9bbbf8 100644
> --- a/ext/pgsql/tests/80_bug32223.phpt
> +++ b/ext/pgsql/tests/80_bug32223.phpt
> @@ -37,8 +37,10 @@ begin
> end;
> ' LANGUAGE plpgsql;");
>
> -
> +$res = pg_query($dbh, 'SET client_min_messages TO NOTICE;');
> +var_dump($res);
> $res = pg_query($dbh, 'SELECT test_notice()');
> +var_dump($res);
> $row = pg_fetch_row($res, 0);
> var_dump($row);
> pg_free_result($res);
> @@ -52,6 +54,8 @@ pg_close($dbh);
> ?>
> ===DONE===
> --EXPECTF--
> +resource(%d) of type (pgsql result)
> +resource(%d) of type (pgsql result)
> array(1) {
> [0]=>
> string(1) "f"
> diff --git a/ext/pgsql/tests/80_bug32223b.phpt
> b/ext/pgsql/tests/80_bug32223b.phpt
> index e79685c..418ccfc 100644
> --- a/ext/pgsql/tests/80_bug32223b.phpt
> +++ b/ext/pgsql/tests/80_bug32223b.phpt
> @@ -37,10 +37,13 @@ begin
> end;
> ' LANGUAGE plpgsql;");
>
> +$res = pg_query(dbh, 'SET client_min_messages TO NOTICE;');
> +var_dump($res);
> +
> function tester() {
> $res = pg_query(dbh, 'SELECT test_notice()');
> $row = pg_fetch_row($res, 0);
> - var_dump($row);
> + var_dump($row);
> pg_free_result($res);
> if ($row[0] == 'f')
> {
> @@ -54,6 +57,7 @@ pg_close(dbh);
> ?>
> ===DONE===
> --EXPECTF--
> +resource(%d) of type (pgsql result)
> array(1) {
> [0]=>
> string(1) "f"
>
>
> --
> PHP CVS Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>