Skip to content
Snippets Groups Projects
Commit 51ab247c authored by catch's avatar catch
Browse files

Issue #3284270 by alexpott, bircher: Reset...

Issue #3284270 by alexpott, bircher: Reset \Drupal\Core\Config\ConfigImporter::$errors in ::validate() method
parent 77702ce7
No related branches found
No related tags found
No related merge requests found
......@@ -729,6 +729,7 @@ protected function getNextConfigurationOperation() {
*/
public function validate() {
if (!$this->validated) {
$this->errors = [];
// Create the list of installs and uninstalls.
$this->createExtensionChangelist();
// Validate renames.
......
......@@ -134,10 +134,9 @@ public function testDeletingStateViaConfiguration() {
$this->fail('ConfigImporterException not thrown, invalid import was not stopped due to deleted workflow.');
}
catch (ConfigImporterException $e) {
$this->assertEquals('There were errors validating the config synchronization.' . PHP_EOL . 'The moderation state Test two is being used, but is not in the source storage.' . PHP_EOL . 'The workflow Editorial is being used, and cannot be deleted.', $e->getMessage());
$this->assertEquals('There were errors validating the config synchronization.' . PHP_EOL . 'The workflow Editorial is being used, and cannot be deleted.', $e->getMessage());
$error_log = $this->configImporter->getErrors();
$expected = [
'The moderation state Test two is being used, but is not in the source storage.',
'The workflow Editorial is being used, and cannot be deleted.',
];
$this->assertEquals($expected, $error_log);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment