function ManageDisplayTest::testNoFieldsDisplayOverview in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/modules/field_ui/src/Tests/ManageDisplayTest.php \Drupal\field_ui\Tests\ManageDisplayTest::testNoFieldsDisplayOverview()
Tests that a message is shown when there are no fields.
File
- core/
modules/ field_ui/ src/ Tests/ ManageDisplayTest.php, line 398 - Contains \Drupal\field_ui\Tests\ManageDisplayTest.
Class
- ManageDisplayTest
- Tests the Field UI "Manage display" and "Manage form display" screens.
Namespace
Drupal\field_ui\TestsCode
function testNoFieldsDisplayOverview() {
// Create a fresh content type without any fields.
NodeType::create(array(
'type' => 'no_fields',
'name' => 'No fields',
))
->save();
$this
->drupalGet('admin/structure/types/manage/no_fields/display');
$this
->assertRaw(t('There are no fields yet added. You can add new fields on the <a href=":link">Manage fields</a> page.', array(
':link' => \Drupal::url('entity.node.field_ui_fields', array(
'node_type' => 'no_fields',
)),
)));
}