You are here

function mongodb_watchdog_test_3219325 in MongoDB 8.2

Create a stack trace specifically formatted to trigger issue 3219325.

@link https://www.drupal.org/project/mongodb/issues/3219325

1 call to mongodb_watchdog_test_3219325()
LoggerTest::testEnhanceLogEntry in modules/mongodb_watchdog/tests/src/Unit/LoggerTest.php
Test for issue #3219325 about closures stack.

File

modules/mongodb_watchdog/tests/modules/mongodb_watchdog_test/mongodb_watchdog_test.module, line 17

Code

function mongodb_watchdog_test_3219325() : array {

  // See \Drupal\mongodb_watchdog\Logger::log()
  $bt = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 10);

  // Fake XDebug being unable to locate the file.
  unset($bt[0]['file']);
  return $bt;
}