alan_k Tue Jul 13 03:12:06 2004 EDT
Modified files:
/php-src/tests/lang 038.phpt
Log:
ensure that test passes on systems without postgres built in.
http://cvs.php.net/diff.php/php-src/tests/lang/038.phpt?r1=1.1&r2=1.2&ty=u
Index: php-src/tests/lang/038.phpt
diff -u php-src/tests/lang/038.phpt:1.1 php-src/tests/lang/038.phpt:1.2
--- php-src/tests/lang/038.phpt:1.1 Sun Jun 27 09:15:31 2004
+++ php-src/tests/lang/038.phpt Tue Jul 13 03:12:06 2004
@@ -5,7 +5,7 @@
class MyException extends Exception
{
- function __construct($errstr, $errno, $errfile, $errline)
+ function __construct($errstr, $errno=0, $errfile='', $errline='')
{
parent::__construct($errstr, $errno);
$this->file = $errfile;
@@ -15,7 +15,7 @@
function Error2Exception($errno, $errstr, $errfile, $errline)
{
- throw new ErrorException($errstr, $errno);//, $errfile, $errline);
+ throw new MyException($errstr, $errno);//, $errfile, $errline);
}
$err_msg = 'no exception';
@@ -23,7 +23,7 @@
try
{
- $con = pg_connect('host=localhost dbname=xtest');
+ $con = fopen("/tmp/a_file_that_does_not_exist",'r');
}
catch (Exception $e)
{
@@ -37,5 +37,5 @@
<?php exit(0); ?>
--EXPECTF--
string(15) "Error2Exception"
-string(10) "pg_connect"
+string(5) "fopen"
===DONE===
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php