Fixes for 4.1 #14

Merged
timw4mail merged 16 commits from develop into master 2018-12-13 14:51:01 -05:00
2 changed files with 7 additions and 7 deletions
Showing only changes of commit 94e61e35a8 - Show all commits

View File

@ -105,7 +105,7 @@ final class ListItem implements ListItemInterface {
$request = $request->setHeader('Authorization', $authHeader); $request = $request->setHeader('Authorization', $authHeader);
} }
$request = $request->getFullReqest(); $request = $request->getFullRequest();
$response = getResponse($request); $response = getResponse($request);
return Json::decode(wait($response->getBody())); return Json::decode(wait($response->getBody()));
} }

View File

@ -39,7 +39,7 @@ class APIRequestBuilderTest extends TestCase {
$this->builder->setLogger(new NullLogger); $this->builder->setLogger(new NullLogger);
} }
public function testGzipRequest() public function testGzipRequest(): void
{ {
$request = $this->builder->newRequest('GET', 'gzip') $request = $this->builder->newRequest('GET', 'gzip')
->getFullRequest(); ->getFullRequest();
@ -48,14 +48,14 @@ class APIRequestBuilderTest extends TestCase {
$this->assertEquals(1, $body['gzipped']); $this->assertEquals(1, $body['gzipped']);
} }
public function testInvalidRequestMethod() public function testInvalidRequestMethod(): void
{ {
$this->expectException(\InvalidArgumentException::class); $this->expectException(\InvalidArgumentException::class);
$this->builder->newRequest('FOO', 'gzip') $this->builder->newRequest('FOO', 'gzip')
->getFullRequest(); ->getFullRequest();
} }
public function testRequestWithBasicAuth() public function testRequestWithBasicAuth(): void
{ {
$request = $this->builder->newRequest('GET', 'headers') $request = $this->builder->newRequest('GET', 'headers')
->setBasicAuth('username', 'password') ->setBasicAuth('username', 'password')
@ -67,7 +67,7 @@ class APIRequestBuilderTest extends TestCase {
$this->assertEquals('Basic dXNlcm5hbWU6cGFzc3dvcmQ=', $body['headers']['Authorization']); $this->assertEquals('Basic dXNlcm5hbWU6cGFzc3dvcmQ=', $body['headers']['Authorization']);
} }
public function testRequestWithQueryString() public function testRequestWithQueryString(): void
{ {
$query = [ $query = [
'foo' => 'bar', 'foo' => 'bar',
@ -95,7 +95,7 @@ class APIRequestBuilderTest extends TestCase {
$this->assertEquals($expected, $body['args']); $this->assertEquals($expected, $body['args']);
} }
public function testFormValueRequest() public function testFormValueRequest(): void
{ {
$formValues = [ $formValues = [
'foo' => 'bar', 'foo' => 'bar',
@ -112,7 +112,7 @@ class APIRequestBuilderTest extends TestCase {
$this->assertEquals($formValues, $body['form']); $this->assertEquals($formValues, $body['form']);
} }
public function testFullUrlRequest() public function testFullUrlRequest(): void
{ {
$data = [ $data = [
'foo' => [ 'foo' => [