protected function AuthenticationTestBase::getEntitiesDataArray in Entity Share 8.3
Helper function to get a mapping of the entities data.
Used to create the entities for the test and to test that it has been recreated properly.
Overrides EntityShareClientFunctionalTestBase::getEntitiesDataArray
1 method overrides AuthenticationTestBase::getEntitiesDataArray()
- AuthenticationAnonymousTest::getEntitiesDataArray in modules/
entity_share_client/ tests/ src/ Functional/ AuthenticationAnonymousTest.php - Helper function to get a mapping of the entities data.
File
- modules/
entity_share_client/ tests/ src/ Functional/ AuthenticationTestBase.php, line 91
Class
- AuthenticationTestBase
- Base class for functional tests of ES authorization plugins.
Namespace
Drupal\Tests\entity_share_client\FunctionalCode
protected function getEntitiesDataArray() {
return [
'file' => [
'en' => $this
->preparePhysicalFilesAndFileEntitiesData(),
],
'node' => [
'en' => [
'es_test_node_import_published' => $this
->getCompleteNodeInfos([
'status' => [
'value' => NodeInterface::PUBLISHED,
'checker_callback' => 'getValue',
],
'field_es_test_file' => [
'value_callback' => function () {
return [
[
'target_id' => $this
->getEntityId('file', 'private_file'),
],
];
},
'checker_callback' => 'getFilteredStructureValues',
],
]),
'es_test_node_import_not_published' => $this
->getCompleteNodeInfos([
'status' => [
'value' => NodeInterface::NOT_PUBLISHED,
'checker_callback' => 'getValue',
],
]),
],
],
];
}