-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Running with --process-isolation yields parse error on global data with single quotes #2
Comments
And just to state the obvious, I circumvented this by changing that line in GlobalState.php to escape single quotes in the data - e.g. From: To: |
Fixed. |
This was referenced Mar 8, 2014
ghost
mentioned this issue
Feb 7, 2016
Closed
This was referenced Aug 22, 2017
axiac
pushed a commit
to axiac/phpunit
that referenced
this issue
May 8, 2018
Now gives better error message: ``` There was 1 error: 1) ExampleTest::testExample PHPUnit_Framework_Exception: Argument sebastianbergmann#2 (string#__construct)of PHPUnit_Framework_MockObject_Generator::getMock() must be a array /<path>/ExampleTest.php:8 ``` Instead of: ``` There was 1 error: 1) ExampleTest::testExample InvalidArgumentException: /<path>/ExampleTest.php:8 ```
Closed
glensc
pushed a commit
to glensc/php-phpunit
that referenced
this issue
Oct 4, 2022
Conditionally avoid method calls deprecated in PHP8
Closed
This issue was closed.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The code that writes out global PHP data to a serialized string doesn't take into account the case where the serialized data contains single quotes - when it does, the string being passed to unserialize results in a parse error.
It's this line:
http://github.com/sebastianbergmann/phpunit/blob/master/PHPUnit/Util/GlobalState.php#L323
The text was updated successfully, but these errors were encountered: