diff --git a/core/tests/Drupal/Tests/BrowserTestBase.php b/core/tests/Drupal/Tests/BrowserTestBase.php index ba08cd5..0689bad 100644 --- a/core/tests/Drupal/Tests/BrowserTestBase.php +++ b/core/tests/Drupal/Tests/BrowserTestBase.php @@ -1847,7 +1847,7 @@ protected function getTestMethodCaller() { $backtrace = debug_backtrace(); // Remove all calls until we reach the current test class. - while (($caller = $backtrace[1]) && + while (isset($backtrace[1]) && ($caller = $backtrace[1]) && (!isset($caller['class']) || $caller['class'] !== get_class($this)) ) { // We remove that call.