more scrutinizer-ci

This commit is contained in:
Ahmad Nassri
2014-12-18 00:08:12 -05:00
parent 97f51e1269
commit d004129842
2 changed files with 3 additions and 2 deletions

View File

@@ -34,7 +34,8 @@ class Response
* thanks to ricardovermeltfoort@gmail.com * thanks to ricardovermeltfoort@gmail.com
* http://php.net/manual/en/function.http-parse-headers.php#112986 * http://php.net/manual/en/function.http-parse-headers.php#112986
*/ */
private function parseHeaders($raw_headers) { private function parseHeaders($raw_headers)
{
if (function_exists('http_parse_headers')) { if (function_exists('http_parse_headers')) {
return http_parse_headers($raw_headers); return http_parse_headers($raw_headers);
} else { } else {

View File

@@ -353,7 +353,7 @@ class UnirestTest extends \PHPUnit_Framework_TestCase
public function testBasicAuthentication() public function testBasicAuthentication()
{ {
$response = Request::get('http://httpbin.org/get', null, array(), 'user', 'password'); $response = Request::get('http://httpbin.org/get', array(), array(), 'user', 'password');
$headers = $response->body->headers; $headers = $response->body->headers;
$this->assertEquals('Basic dXNlcjpwYXNzd29yZA==', $headers->Authorization); $this->assertEquals('Basic dXNlcjpwYXNzd29yZA==', $headers->Authorization);
} }