(now: Date = new Date())
| 22 | * Format: debug-YYYY-MM-DD_HH-mm-ss.log |
| 23 | */ |
| 24 | export function generateLogFileName(now: Date = new Date()): string { |
| 25 | const date = `${now.getFullYear()}-${pad(now.getMonth() + 1)}-${pad(now.getDate())}`; |
| 26 | const time = `${pad(now.getHours())}-${pad(now.getMinutes())}-${pad(now.getSeconds())}`; |
| 27 | return `debug-${date}_${time}.log`; |
| 28 | } |
| 29 | |
| 30 | /** |
| 31 | * Format a single log line using local time (consistent with file name). |
no test coverage detected