'clearfix text-formatted field field--name-test-display-multiple field--type-text field--label-above',
];
$this->
assertFieldAttributes($this->entity,
$expected_fields);
$this->
installLayoutBuilder();
// Without using Layout Builder for an override, the result has not changed.
$this->
assertFieldAttributes($this->entity,
$expected_fields);
// Add a layout override.
$this->
enableOverrides();
$this->entity =
$this->
reloadEntity($this->entity
);
$this->entity->
get(OverridesSectionStorage::FIELD_NAME
)->
appendSection(new Section('layout_onecol'
));
$this->entity->
save();
// The rendered entity has now changed. The non-configurable field is shown
// outside the layout, the configurable field is not shown at all, and the
// layout itself is rendered (but empty).
$new_expected_fields =
[ 'field field--name-name field--type-string field--label-hidden field__item',
'clearfix text-formatted field field--name-test-display-non-configurable field--type-text field--label-above',
'clearfix text-formatted field field--name-test-display-multiple field--type-text field--label-above',
];