COM-45 :: Adjust Guzzle Tests
This commit is contained in:
@@ -58,7 +58,7 @@ class GuzzleTest extends PHPUnit_Framework_TestCase
|
||||
$this->assertEquals("application/json", $headers["Content-Type"][0]);
|
||||
|
||||
$body = json_decode($response->getBody());
|
||||
$this->assertEquals("Testing a PUT request.", $body->json->{"X-Put-Test"});
|
||||
$this->assertEquals("Testing a PUT request.", json_decode($body->json)->{"X-Put-Test"});
|
||||
}
|
||||
|
||||
public function testPatch()
|
||||
@@ -70,7 +70,7 @@ class GuzzleTest extends PHPUnit_Framework_TestCase
|
||||
$this->assertEquals("application/json", $headers["Content-Type"][0]);
|
||||
|
||||
$body = json_decode($response->getBody());
|
||||
$this->assertEquals("Testing a PATCH request.", $body->json->{"X-Patch-Test"});
|
||||
$this->assertEquals("Testing a PATCH request.", json_decode($body->json)->{"X-Patch-Test"});
|
||||
}
|
||||
|
||||
public function testDelete()
|
||||
@@ -82,7 +82,7 @@ class GuzzleTest extends PHPUnit_Framework_TestCase
|
||||
$this->assertEquals("application/json", $headers["Content-Type"][0]);
|
||||
|
||||
$body = json_decode($response->getBody());
|
||||
$this->assertEquals("Testing a DELETE request.", $body->form->{"X-Delete-Test"});
|
||||
$this->assertEquals("Testing a DELETE request.", $body->json->{"X-Delete-Test"});
|
||||
}
|
||||
|
||||
public function testErrors()
|
||||
|
||||
Reference in New Issue
Block a user