public function ConfigEntityRevisionsRevertFormTest2::prepareToPublishCurrentRevision in Config Entity Revisions 8.2
Same name and namespace in other branches
- 8 tests/src/Unit/ConfigEntityRevisionsRevertFormBaseTest.php \Drupal\Tests\config_entity_revisions\Unit\ConfigEntityRevisionsRevertFormTest2::prepareToPublishCurrentRevision()
- 1.x tests/src/Unit/ConfigEntityRevisionsRevertFormBaseTest.php \Drupal\Tests\config_entity_revisions\Unit\ConfigEntityRevisionsRevertFormTest2::prepareToPublishCurrentRevision()
Override prepareToPublishCurrentRevision to ensure it is actually called.
Parameters
\Drupal\config_entity_revisions\ConfigEntityRevisionsConfigEntityInterface $revision: The revision to be published.
Return value
\Drupal\config_entity_revisions\ConfigEntityRevisionsConfigEntityInterface The resulting revision record, ready to be saved.
Overrides ConfigEntityRevisionsRevertFormBase::prepareToPublishCurrentRevision
File
- tests/
src/ Unit/ ConfigEntityRevisionsRevertFormBaseTest.php, line 622
Class
- ConfigEntityRevisionsRevertFormTest2
- Override revision preparation so we can test the applyRevisionChange method.
Namespace
Drupal\Tests\config_entity_revisions\UnitCode
public function prepareToPublishCurrentRevision(ConfigEntityRevisionsConfigEntityInterface $revision) {
$this->prepareToPublishCurrentRevisionCalled = TRUE;
return $revision;
}