Home > Archive > PHP PEAR Questions and Answers > April 2004 > Re: [PEAR-QA] pear run-tests
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Re: [PEAR-QA] pear run-tests
|
|
| Stephan Schmidt 2004-04-29, 5:17 pm |
| Hi,
> Running tests in /usr/local/lib/php/tests/XML_Parser/tests
> ========================================
==================
> XML Parser: parse simple string (001.phpt) ...
> failed
> XML Parser: parse from file (002.phpt) ...
> failed
> XML Parser: parse from file resource (003.phpt) ...
> failed
> XML Parser: error class (004.phpt) ...
> failed
> XML Parser: mixing character encodings (005.phpt) ...
> failed
I'm trying to reproduce this, but I have trouble running the tests...
On my linux machine I get:
ERROR: Cannot open file '/usr/share/php/run-test-info.php' (save_text)
And on windows:
C:\www\projects\pear\XML_Parser>pear run-tests
Error in argument 1, char 2: option not found r
Error in argument 1, char 2: option not found r
========================================
=============================
CWD : C:\www\projects\pear\XML_Parser
PHP : c:\php4/php.exe Content-type: text/html
X-Powered-By: PHP/4.3.4
PHP_SAPI : cgi-fcgi
PHP_VERSION : 4.3.4
ZEND_VERSION: 1.3.0
PHP_OS : WINNT - Windows NT GRACELAND 5.1 build 2600
INI actual : C:\WINDOWS\php.ini
More .INIs :
Extra dirs :
========================================
=============================
<br />
<table border='1' cellspacing='0'>
<tr><td bgcolor='#ffbbbb' colspan="3"><b>Warning</b>:
opendir(C:\www\projects\pear\XML_Parser/pear): failed to open dir:
Invalid argument in <b>C:\php
4\pear\run-tests.php</b> on line <b>237</b><br />
<tr><th bgcolor='#aaaaaa' colspan='3'>Call Stack</th></tr>
<tr><th bgcolor='#cccccc'>#</th><th bgcolor='#cccccc'>Function</th><th
bgcolor='#cccccc'>Location</th></tr>
<tr><td bgcolor='#ffffff' align='center'>1</td><td
bgcolor='#ffffff'>{main}()</td><td
bgcolor='#ffffff'>C:\php4\pear\run-tests.php<b>:</b>0</td></tr>
<tr><td bgcolor='#ffffff' align='center'>2</td><td
bgcolor='#ffffff'>find_files()</td><td
bgcolor='#ffffff'>C:\php4\pear\run-tests.php<b>:</b>226</td>
</tr>
<tr><td bgcolor='#ffffff' align='center'>3</td><td bgcolor='#ffffff'><a
href='http://www.php.net/opendir' target='_new'>opendir</a>
()</td><td bgcolor='#ffffff'>C:\php4\pear\run-tests.php<b>:</b>237</td></tr>
</table>
ERROR: cannot open directory: C:\www\projects\pear\XML_Parser/pear
I ran the tests manually before the release and they have been working....
Stephan
| |
| Mika Tuupola 2004-04-30, 2:15 am |
| On Thu, 29 Apr 2004, Stephan Schmidt wrote:
> ERROR: Cannot open file '/usr/share/php/run-test-info.php' (save_text)
Try to run as root.
--
Mika Tuupola http://www.appelsiini.net/~tuupola/
| |
| Stephan Schmidt 2004-04-30, 2:15 am |
| Hi,
>
>
> Try to run as root.
Then I get the same error as on my Windows machine:
schst@rot2:tests> sudo pear run-tests
Password:
========================================
=============================
CWD : /home/schst/pear/pear/XML_Parser/tests
PHP : /usr/bin/php
PHP_SAPI : cli
PHP_VERSION : 4.3.3
ZEND_VERSION: 1.3.0
PHP_OS : Linux - Linux rot2.de 2.4.18-bf2.4 #1 Fri Jun 7 06:12:37
UTC 2002 i686
INI actual : /etc/php4/cgi/php.ini
More .INIs :
Extra dirs :
========================================
=============================
Warning: opendir(/home/schst/pear/pear/XML_Parser/tests/tests): failed
to open dir: No such file or directory in /usr/share/php/run-tests.php
on line 237
ERROR: cannot open directory: /home/schst/pear/pear/XML_Parser/tests/tests
If I run it in the parent dir, I get
ERROR: cannot open directory: /home/schst/pear/pear/XML_Parser/pear
Stephan
| |
| Mika Tuupola 2004-04-30, 2:15 am |
| On Thu, 29 Apr 2004, Stephan Schmidt wrote:
> schst@rot2:tests> sudo pear run-tests
I usually run it as (while in tests/ directory)
pear run-tests ./
--
Mika Tuupola http://www.appelsiini.net/~tuupola/
| |
| Stephan Schmidt 2004-04-30, 2:15 am |
| Hi,
> I usually run it as (while in tests/ directory)
>
> pear run-tests ./
Thanks!
It worked, and I get:
schst@rot2:tests> sudo pear run-tests ./
========================================
=============================
CWD : /home/schst/pear/pear/XML_Parser/tests
PHP : /usr/bin/php
PHP_SAPI : cli
PHP_VERSION : 4.3.3
ZEND_VERSION: 1.3.0
PHP_OS : Linux - Linux rot2.de 2.4.18-bf2.4 #1 Fri Jun 7 06:12:37
UTC 2002 i686
INI actual : /etc/php4/cgi/php.ini
More .INIs :
Extra dirs :
========================================
=============================
Running selected tests.
PASS XML Parser: parse simple string [001.phpt]
FAIL XML Parser: parse from file [002.phpt]
FAIL XML Parser: parse from file resource [003.phpt]
PASS XML Parser: error class [004.phpt]
PASS XML Parser: mixing character encodings [005.phpt]
Before and after upgrading...
An the two that fail, just fail because of different resource IDs:
002- setInputFile resource(7) of type (stream)
002+ setInputFile resource(6) of type (stream)
I guess, I should adjust the test files.
Lukas, could you send me the actual and expected results?
Stephan
| |
| Mika Tuupola 2004-04-30, 9:34 am |
| On Thu, 29 Apr 2004, Stephan Schmidt wrote:
> Before and after upgrading...
>
> An the two that fail, just fail because of different resource IDs:
>
> 002- setInputFile resource(7) of type (stream)
> 002+ setInputFile resource(6) of type (stream)
>
> I guess, I should adjust the test files.
>
> Lukas, could you send me the actual and expected results?
Look in the .phpt file. The expected result is after
"--EXPECT--". The actual output for failed tests can
be found in .out files. The differences between expected
and actual result in .diff files.
--
Mika Tuupola http://www.appelsiini.net/~tuupola/
| |
| Stephan Schmidt 2004-04-30, 9:35 am |
| Hi,
> Look in the .phpt file. The expected result is after
> "--EXPECT--". The actual output for failed tests can
> be found in .out files. The differences between expected
> and actual result in .diff files.
I know, on my machine, the tests succeeded, that's why I aksed Lukas to
send me the diffs for the tests that failed.
Stephan
| |
| Mika Tuupola 2004-04-30, 9:35 am |
| On Fri, 30 Apr 2004, Stephan Schmidt wrote:
> I know, on my machine, the tests succeeded, that's why I aksed Lukas to
> send me the diffs for the tests that failed.
Ah sorry. Misunderstood the mail.
--
Mika Tuupola http://www.appelsiini.net/~tuupola/
|
|
|
|
|