Revert "merged branch jfsimon/issue-4475 (PR #4497)"
This reverts commitf8a09db5e2
, reversing changes made toae2ec36e27
.
This commit is contained in:
parent
f8a09db5e2
commit
fc40e53724
|
@ -1028,14 +1028,6 @@
|
|||
decoded twice before. Note that the `urldecode()` calls have been changed for a
|
||||
single `rawurldecode()` in order to support `+` for input paths.
|
||||
|
||||
### BrowserKit
|
||||
|
||||
#### BC Breaks
|
||||
|
||||
* The Symfony\Component\HttpKernel\Client::request() method
|
||||
now returns a Symfony\Component\BrowserKit\Response instance
|
||||
(instead of a Symfony\Component\HttpFoundation\Response instance)
|
||||
|
||||
### FrameworkBundle
|
||||
|
||||
* session options: lifetime, path, domain, secure, httponly were deprecated.
|
||||
|
|
|
@ -4,9 +4,5 @@ CHANGELOG
|
|||
2.1.0
|
||||
-----
|
||||
|
||||
* [BR BREAK] The Symfony\Component\HttpKernel\Client::request() method
|
||||
now returns a Symfony\Component\BrowserKit\Response instance
|
||||
(instead of a Symfony\Component\HttpFoundation\Response instance)
|
||||
|
||||
* [BC BREAK] The CookieJar internals have changed to allow cookies with the
|
||||
same name on different sub-domains/sub-paths
|
||||
|
|
|
@ -264,17 +264,17 @@ abstract class Client
|
|||
$this->response = $this->doRequest($this->request);
|
||||
}
|
||||
|
||||
$this->response = $this->filterResponse($this->response);
|
||||
$response = $this->filterResponse($this->response);
|
||||
|
||||
$this->cookieJar->updateFromResponse($this->response);
|
||||
$this->cookieJar->updateFromResponse($response);
|
||||
|
||||
$this->redirect = $this->response->getHeader('Location');
|
||||
$this->redirect = $response->getHeader('Location');
|
||||
|
||||
if ($this->followRedirects && $this->redirect) {
|
||||
return $this->crawler = $this->followRedirect();
|
||||
}
|
||||
|
||||
return $this->crawler = $this->createCrawlerFromContent($request->getUri(), $this->response->getContent(), $this->response->getHeader('Content-Type'));
|
||||
return $this->crawler = $this->createCrawlerFromContent($request->getUri(), $response->getContent(), $response->getHeader('Content-Type'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -11,7 +11,6 @@
|
|||
|
||||
namespace Symfony\Component\HttpKernel\Tests;
|
||||
|
||||
use Symfony\Component\BrowserKit\Response as DomResponse;
|
||||
use Symfony\Component\HttpKernel\Client;
|
||||
use Symfony\Component\HttpKernel\HttpKernel;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
|
@ -35,7 +34,6 @@ class ClientTest extends \PHPUnit_Framework_TestCase
|
|||
|
||||
$client->request('GET', '/');
|
||||
$this->assertEquals('Request: /', $client->getResponse()->getContent(), '->doRequest() uses the request handler to make the request');
|
||||
$this->assertTrue($client->getResponse() instanceof DomResponse, '->getResponse() returns a Symfony\Component\BrowserKit\Response instance');
|
||||
|
||||
$client->request('GET', 'http://www.example.com/');
|
||||
$this->assertEquals('Request: /', $client->getResponse()->getContent(), '->doRequest() uses the request handler to make the request');
|
||||
|
|
Reference in New Issue