public function fill($data)
{
$this->data = $data;
$this->lastError = $this->getValueByKey('resource_response.error', $this->data);
$this->clientInfo = $this->getValueByKey('client_context', $this->data);
}
/** @test */ public function it_should_return_data_and_bookmarks_from_response_with_pagination() { $dataWithBookmarks = ['resource' => ['options' => ['bookmarks' => ['my_bookmarks_string']]], 'resource_response' => ['data' => 'some data']]; $response = new Response(); $response->fill($dataWithBookmarks); $expected = ['data' => 'some data', 'bookmarks' => ['my_bookmarks_string']]; $this->assertEquals($expected, $response->getPaginationData()); }