diff --git a/core/modules/field_ui/src/Tests/ManageFieldsTest.php b/core/modules/field_ui/src/Tests/ManageFieldsTest.php index 2255f29..fb4a5e6 100644 --- a/core/modules/field_ui/src/Tests/ManageFieldsTest.php +++ b/core/modules/field_ui/src/Tests/ManageFieldsTest.php @@ -627,6 +627,18 @@ public function testExternalDestinations() { // The external redirect should not fire. $this->assertUrl('admin/structure/types/manage/article/fields/node.article.body/storage', $options); $this->assertResponse(400); + + foreach ($this->assertions as $id => $assertion) { + if ($assertion['status'] === 'exception') { + // Ensure that the right error is thrown. + $this->assertEqual('User error', $assertion['message_group']); + $this->assertEqual('Redirects to external URLs are not allowed by default, use \Drupal\Core\Routing\RedirectResponseAllowExternalUrl for it', $assertion['message']); + // Finally remove that exception entry in order to not fail the test + // itself. + unset($this->assertions[$id]); + $this->deleteAssert($assertion['message_id']); + } + } } /**