protected function SysLogTest::syslogWrapper in Drupal 10
Same name and namespace in other branches
- 8 core/modules/syslog/tests/modules/syslog_test/src/Logger/SysLogTest.php \Drupal\syslog_test\Logger\SysLogTest::syslogWrapper()
- 9 core/modules/syslog/tests/modules/syslog_test/src/Logger/SysLogTest.php \Drupal\syslog_test\Logger\SysLogTest::syslogWrapper()
File
- core/
modules/ syslog/ tests/ modules/ syslog_test/ src/ Logger/ SysLogTest.php, line 16
Class
- SysLogTest
- Redirects logging messages to error_log.
Namespace
Drupal\syslog_test\LoggerCode
protected function syslogWrapper($level, $entry) {
$log_path = \Drupal::service('file_system')
->realpath('public://syslog.log');
error_log($entry . PHP_EOL, 3, $log_path);
}