php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #50836 run_tests.php alerts syntax errors while testing session
Submitted: 2010-01-25 18:46 UTC Modified: 2010-08-16 22:56 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: v-ryanbi at microsoft dot com Assigned: kalle (profile)
Status: Closed Package: Session related
PHP Version: 5.3SVN-2010-01-25 (SVN) OS: win32 only
Private report: No CVE-ID: None
 [2010-01-25 18:46 UTC] v-ryanbi at microsoft dot com
Description:
------------
During execution of 'run-tests.php' from the cmd shell, at several points an alert dialog is created, bypassing stdout and stderr. The contents of the alert is:

---------------------------
PHP Error
---------------------------
parse error, expecting `TC_DOLLAR_CURLY' or `TC_QUOTED_STRING' or `'\"'' in Unknown on line 39

---------------------------
OK   
---------------------------

It appears twice immediately after each of the following outputs, none of which have 39 lines, so I'm suspecting it's failing on eval'd code at some point:

TEST 3029/8140 ext\session\tests\020.phpt
TEST 3047/8140 ext\session\tests\bug41600.phpt
TEST 3048/8140 ext\session\tests\bug42596.phpt

No syntax errors are present in the --FILE section of the tests or in the files generated.

Reproduce code:
---------------
C:\>SET PHP_TEST_EXECUTABLE=C:\path\to\php\source\Release\php.exe
C:\>cd \path\to\php\source
C:\path\to\php\source>Release\php.exe run-tests.php

Expected result:
----------------
No errors would be nice :)

Actual result:
--------------
See Description

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-01-25 19:37 UTC] pajoye@php.net
That's due to the (somehow broken) --INI-- section:

arg_separator.output="&"

If you replace this line with:

arg_separator.output=&

it should work well.

I don't have a work around for run-tests.php right now, patch welcome if you find a portable solution (has to work on all platforms).
 [2010-01-25 19:38 UTC] v-ryanbi at microsoft dot com
Upon further inspection, I found the test log files potentially relevant. All three tests actual output is the same. 

ext\session\tests\020.log
---- EXPECTED OUTPUT
<a href="link.php?a=b&amp;PHPSESSID=abtest">
---- ACTUAL OUTPUT
'amp' is not recognized as an internal or external command,
operable program or batch file.
---- FAILED

ext\session\tests\bug41600.log
---- EXPECTED OUTPUT
<a href="link.php?a=b&amp;PHPSESSID=abtest">
---- ACTUAL OUTPUT
'amp' is not recognized as an internal or external command,
operable program or batch file.
---- FAILED

ext\session\tests\bug42596.log
---- EXPECTED OUTPUT
hello world
string(6) "100777"
---- ACTUAL OUTPUT
'amp' is not recognized as an internal or external command,
operable program or batch file.
---- FAILED
 [2010-08-16 22:37 UTC] kalle@php.net
I fixed that a few years ago, but Jani, as usual went crazy and removed my patch. The fix is simply to dig into run-tests.php, and escape " for Windows only
 [2010-08-16 22:56 UTC] kalle@php.net
Automatic comment from SVN on behalf of kalle
Revision: http://svn.php.net/viewvc/?view=revision&amp;revision=302373
Log: Fixed bug #50836 (run_tests.php alerts syntax errors while testing session)
 [2010-08-16 22:56 UTC] kalle@php.net
-Status: Assigned +Status: Closed -Assigned To: pajoye +Assigned To: kalle
 [2010-08-16 22:56 UTC] kalle@php.net
This bug has been fixed in SVN.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 02:01:29 2024 UTC