diff -u b/core/tests/Drupal/KernelTests/Core/Entity/ContentEntitySerializationTest.php b/core/tests/Drupal/KernelTests/Core/Entity/ContentEntitySerializationTest.php --- b/core/tests/Drupal/KernelTests/Core/Entity/ContentEntitySerializationTest.php +++ b/core/tests/Drupal/KernelTests/Core/Entity/ContentEntitySerializationTest.php @@ -111,6 +111,10 @@ if ($deep_serialization) { $entity_level_zero->setDeepSerialization(TRUE); } + + // Serialize and then unserialize the entity in order to check that the + // entity has been properly serialized depending on the used serialization + // method - regular or deep serialization. $entity_level_zero = unserialize(serialize($entity_level_zero)); // If regular serialization is tested then the changes on the referenced