$test_name =
reset($names);
$source->
setValue($test_name, FALSE
);
$logger_factory =
$this->
prophesize(LoggerChannelFactoryInterface::
class);
$container =
new ContainerBuilder();
$container->
set('logger.factory',
$logger_factory->
reveal());
\Drupal::
setContainer($container);
// Reading a config storage with an invalid configuration logs a notice.
$channel =
$this->
prophesize(LoggerChannelInterface::
class);
$logger_factory->
get('config'
)->
willReturn($channel->
reveal());
$channel->
notice('Missing required data for configuration: %config', Argument::
withEntry('%config',
$test_name))->
shouldBeCalled();
// Copy the config from the source storage to the target storage.
$target =
new TestStorage();
self::
replaceStorageContents($source,
$target);
// Test that all configuration is copied correctly and that the value of the
// config with the invalid configuration has not been copied to the target
// storage.
foreach ($names as $name) { if ($name ===
$test_name) { $this->
assertFalse($source->
read($name));