mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 06:08:52 +00:00
[ticket/10981] Modified functional framework to account for goutte changes
PHPBB3-10981
This commit is contained in:
parent
797ee16eaf
commit
d88411e10d
1 changed files with 6 additions and 3 deletions
|
@ -46,7 +46,10 @@ class phpbb_functional_test_case extends phpbb_test_case
|
|||
}
|
||||
|
||||
$this->cookieJar = new CookieJar;
|
||||
$this->client = new Goutte\Client(array(), array(), null, $this->cookieJar);
|
||||
$this->client = new Goutte\Client(array(), null, $this->cookieJar);
|
||||
// Reset the curl handle because it is 0 at this point and not a valid
|
||||
// resource
|
||||
$this->client->getClient()->getCurlMulti()->reset(true);
|
||||
$this->root_url = self::$config['phpbb_functional_url'];
|
||||
// Clear the language array so that things
|
||||
// that were added in other tests are gone
|
||||
|
@ -191,9 +194,9 @@ class phpbb_functional_test_case extends phpbb_test_case
|
|||
$cookies = $this->cookieJar->all();
|
||||
|
||||
// The session id is stored in a cookie that ends with _sid - we assume there is only one such cookie
|
||||
foreach ($cookies as $key => $cookie);
|
||||
foreach ($cookies as $cookie);
|
||||
{
|
||||
if (substr($key, -4) == '_sid')
|
||||
if (substr($cookie->getName(), -4) == '_sid')
|
||||
{
|
||||
$this->sid = $cookie->getValue();
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue