$components[] =
$non_derivative_component->
reveal();
// Ensure a derivative component with a different base Id is not returned.
$derivative_non_inline_component =
$prophet->
prophesize(SectionComponent::
class);
$plugin =
$prophet->
prophesize(DerivativeInspectionInterface::
class);
$plugin->
getBaseId()->
willReturn('some_other_base_id_which_we_do_not_care_about_but_it_is_nothing_personal'
);
$derivative_non_inline_component->
getPlugin()->
willReturn($plugin);
$components[] =
$derivative_non_inline_component->
reveal();
// Ensure that inline block component is returned.
$inline_component =
$prophet->
prophesize(SectionComponent::
class);
$inline_plugin =
$prophet->
prophesize(DerivativeInspectionInterface::
class)->
willImplement(ConfigurableInterface::
class);
$inline_plugin->
getBaseId()->
willReturn('inline_block'
);
$inline_plugin->
getConfiguration()->
willReturn(['block_revision_id' => 'the_revision_id'
]);
$inline_component->
getPlugin()->
willReturn($inline_plugin->
reveal());
$inline_component =
$inline_component->
reveal();
$components[] =
$inline_component;
// Ensure that inline block component without revision is returned.
$inline_component_without_revision_id =
$prophet->
prophesize(SectionComponent::
class);
$inline_plugin_without_revision_id =
$prophet->
prophesize(DerivativeInspectionInterface::
class)->
willImplement(ConfigurableInterface::
class);
$inline_plugin_without_revision_id->
getBaseId()->
willReturn('inline_block'
);
$inline_plugin_without_revision_id->
getConfiguration()->
willReturn(['other_key' => 'other_value'
]);