protected function ImportExportTestBase::populateCdfObject in Acquia Content Hub 8.2
Populates CDF object from array.
Parameters
array $data: CDFObject data.
Return value
\Acquia\ContentHubClient\CDF\CDFObject Populated CDF object.
Throws
\Exception
See also
\Acquia\ContentHubClient\ContentHubClient::getEntities()
1 call to ImportExportTestBase::populateCdfObject()
- ImportExportTestBase::createCdfDocumentFromFixture in tests/
src/ Kernel/ ImportExportTestBase.php - Creates CDF document from fixture.
File
- tests/
src/ Kernel/ ImportExportTestBase.php, line 168
Class
- ImportExportTestBase
- Base for testing exports and imports.
Namespace
Drupal\Tests\acquia_contenthub\KernelCode
protected function populateCdfObject(array $data) {
$event = new GetCDFTypeEvent($data);
$subscriber = new DefaultCDF();
$subscriber
->onGetCDFType($event);
return $event
->getObject();
}