function testFillDatabase() { $json = file_get_contents(__DIR__ . '/' . $this->fixturesFolder . '/get-database.json'); $jsonObj = json_decode($json); $database = new Database(); $database->setDatabaseId($jsonObj->database_id)->setTitle($jsonObj->title)->setSize($jsonObj->size)->setRevision($jsonObj->revision)->setRecordsCount($jsonObj->records_count)->setModified($jsonObj->modified)->setCreated($jsonObj->modified); $arrayDiff = array_diff($database->toArray(), json_decode($json, true)); $this->assertTrue(empty($arrayDiff), 'Is Equals arrays'); }