diff --git a/core/tests/Drupal/KernelTests/Core/Entity/ConfigEntityAdapterTest.php b/core/tests/Drupal/KernelTests/Core/Entity/ConfigEntityAdapterTest.php index eaa01e7936..4d24e9511a 100644 --- a/core/tests/Drupal/KernelTests/Core/Entity/ConfigEntityAdapterTest.php +++ b/core/tests/Drupal/KernelTests/Core/Entity/ConfigEntityAdapterTest.php @@ -116,8 +116,14 @@ public function testGetProperty() { */ public function testSetProperty() { $adapter = ConfigEntityAdapter::createFromEntity($this->entity); + // Get the value via typed data to ensure that the typed representation is + // updated correctly when the value is set. + $this->assertEquals(1, $adapter->get('weight')->getValue()); + $adapter->set('weight', 2); $this->assertEquals(2, $this->entity->weight); + // Ensure the typed data is updated via the set too. + $this->assertEquals(2, $adapter->get('weight')->getValue()); } /**