protected function NormalizerTestBase::setUp in Zircon Profile 8
Same name in this branch
- 8 core/modules/hal/src/Tests/NormalizerTestBase.php \Drupal\hal\Tests\NormalizerTestBase::setUp()
- 8 core/modules/serialization/src/Tests/NormalizerTestBase.php \Drupal\serialization\Tests\NormalizerTestBase::setUp()
Same name and namespace in other branches
- 8.0 core/modules/serialization/src/Tests/NormalizerTestBase.php \Drupal\serialization\Tests\NormalizerTestBase::setUp()
Overrides KernelTestBase::setUp
2 calls to NormalizerTestBase::setUp()
- EntityResolverTest::setUp in core/
modules/ serialization/ src/ Tests/ EntityResolverTest.php - EntitySerializationTest::setUp in core/
modules/ serialization/ src/ Tests/ EntitySerializationTest.php
2 methods override NormalizerTestBase::setUp()
- EntityResolverTest::setUp in core/
modules/ serialization/ src/ Tests/ EntityResolverTest.php - EntitySerializationTest::setUp in core/
modules/ serialization/ src/ Tests/ EntitySerializationTest.php
File
- core/
modules/ serialization/ src/ Tests/ NormalizerTestBase.php, line 23 - Contains \Drupal\serialization\Tests\NormalizerTestBase.
Class
Namespace
Drupal\serialization\TestsCode
protected function setUp() {
parent::setUp();
$this
->installEntitySchema('entity_test_mulrev');
$this
->installEntitySchema('user');
$this
->installSchema('system', array(
'url_alias',
'router',
));
$this
->installConfig(array(
'field',
));
\Drupal::service('router.builder')
->rebuild();
\Drupal::moduleHandler()
->invoke('rest', 'install');
// Auto-create a field for testing.
FieldstorageConfig::create(array(
'entity_type' => 'entity_test_mulrev',
'field_name' => 'field_test_text',
'type' => 'text',
'cardinality' => 1,
'translatable' => FALSE,
))
->save();
FieldConfig::create(array(
'entity_type' => 'entity_test_mulrev',
'field_name' => 'field_test_text',
'bundle' => 'entity_test_mulrev',
'label' => 'Test text-field',
'widget' => array(
'type' => 'text_textfield',
'weight' => 0,
),
))
->save();
}