You are here

public function ConfigEntityRevisionsRevertFormBaseTest::updateConfigEntityModifiesEntityCorrectly in Config Entity Revisions 1.x

Same name and namespace in other branches
  1. 8.2 tests/src/Unit/ConfigEntityRevisionsRevertFormBaseTest.php \Drupal\Tests\config_entity_revisions\Unit\ConfigEntityRevisionsRevertFormBaseTest::updateConfigEntityModifiesEntityCorrectly()
  2. 8 tests/src/Unit/ConfigEntityRevisionsRevertFormBaseTest.php \Drupal\Tests\config_entity_revisions\Unit\ConfigEntityRevisionsRevertFormBaseTest::updateConfigEntityModifiesEntityCorrectly()

updateConfigEntity should update the config entity as expected.

@test

File

tests/src/Unit/ConfigEntityRevisionsRevertFormBaseTest.php, line 458

Class

ConfigEntityRevisionsRevertFormBaseTest

Namespace

Drupal\Tests\config_entity_revisions\Unit

Code

public function updateConfigEntityModifiesEntityCorrectly() {
  $this->instance = $this
    ->getMockInstance(300, 'ConfigEntityRevisionsRevertFormTest2');
  $this->instance
    ->updateConfigEntity();
  $this
    ->assertTrue($this->serializer->wasCalled);
  $this
    ->assertEquals([
    'settingsOriginal' => 'originalSettings',
    'revision_id' => 300,
  ], $this->serializer->keyValuePairs);
}