diff --git a/core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php b/core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php index f6c34084ba..00b6f761ae 100644 --- a/core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php +++ b/core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php @@ -46,7 +46,10 @@ private function getProxyInstantiator() } /** - * {@inheritdoc} + * A 1to1 copy of parent::shareService. + * + * @todo https://www.drupal.org/project/drupal/issues/2937010 Since Symfony + * 3.4 this is not a 1to1 copy. */ protected function shareService(Definition $definition, $service, $id, array &$inlineServices) { @@ -113,6 +116,9 @@ public function setParameter($name, $value) { /** * A 1to1 copy of parent::callMethod. + * + * @todo https://www.drupal.org/project/drupal/issues/2937010 Since Symfony + * 3.4 this is not a 1to1 copy. */ protected function callMethod($service, $call, array &$inlineServices = array()) { $services = self::getServiceConditionals($call[1]); diff --git a/core/tests/Drupal/Tests/Component/Serialization/YamlTest.php b/core/tests/Drupal/Tests/Component/Serialization/YamlTest.php index e627715637..b74a64fe4f 100644 --- a/core/tests/Drupal/Tests/Component/Serialization/YamlTest.php +++ b/core/tests/Drupal/Tests/Component/Serialization/YamlTest.php @@ -102,7 +102,13 @@ public function testObjectSupportDisabledPecl() { * @see \Drupal\Tests\Component\Serialization\YamlTest::testObjectSupportDisabledPecl() */ public function testObjectSupportDisabledSymfony() { - $this->setExpectedExceptionRegExp(InvalidDataTypeException::class, '/^Object support when parsing a YAML file has been disabled/'); + if (method_exists($this, 'setExpectedExceptionRegExp')) { + $this->setExpectedExceptionRegExp(InvalidDataTypeException::class, '/^Object support when parsing a YAML file has been disabled/'); + } + else { + $this->expectException(InvalidDataTypeException::class); + $this->expectExceptionMessageRegExp('/^Object support when parsing a YAML file has been disabled/'); + } $object = new \stdClass(); $object->foo = 'bar'; // In core all Yaml encoding is done via Symfony and it does not support