Closed (outdated)
Project:
Drupal core
Version:
9.1.x-dev
Component:
phpunit
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
16 Aug 2015 at 21:58 UTC
Updated:
17 Jul 2020 at 14:10 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
berdirI'm not sure if BrowserTestBase needs to be changed as well.
Comment #3
dawehnerWe should certainly at least document why we use
$_COOKIEhereComment #4
jibranWhere can I read the documents about this? I know this feature is there but I don't know how to use this.
Comment #5
rocketeerbkw commented\Drupal::request()returns the last request on the request stack (Symfony\Component\HttpFoundation\RequestStack). When I was debugging this, the stack had at least 5 request objects in it, none of the later ones had cookies.I don't know why there are so many, but I know that the first one in the stack has all the cookies in it, so I changed the code to get the first request object in the stack. This fixed it for me, and it doesn't have to use
$_COOKIEglobal.Comment #6
rocketeerbkw commentedComment #8
juampynr commentedI just verified that the patch at #6 gets the cookie information from the master request:
However, I don't know what to set to the XDEBUG_SESSION cookie so the correct info is then added to get/post request to the child site. I tried running
document.cookie="document.cookie="XDEBUG_SESSION=xdebug;path=/";just before clicking "Run tests" and even though I can see the cookie in the above screenshot, this does not add the XDEBUG_SESSION_START parameter to child requests.@rocketeerbkw, how do you do it?
On a side note, once we fix this issue we should update #30011: Miscellaneous SimpleTest tips
Comment #10
juampynr commentedSince I changed to PHPStorm I am not facing this error again by upping the Number of connection settings. Shall we close this issue?
@rocketeerbkw, do you still experience this issue?
Comment #18
quietone commentedTriaging issues in simpletest.module as part of the Bug Smash Initiative to determine if they should be in the Simpletest Project or core.
This looks like it a Phpunit issue, changing component.
Comment #19
mondrakeWell this one seems definitely outdated. If still applies for BrowserTestBase, please ipen a new issue.