fix(logging): Improve warning logging and add permission settings file

This commit is contained in:
2025-05-24 11:10:49 +00:00
parent e1d90589bc
commit 0954265095
4 changed files with 25 additions and 5 deletions

View File

@@ -443,6 +443,20 @@ export class TsTestLogger {
this.log(this.format(`\n${status}`, statusColor));
}
// Warning display
warning(message: string) {
if (this.options.json) {
this.logJson({ event: 'warning', message });
return;
}
if (this.options.quiet) {
console.log(`WARNING: ${message}`);
} else {
this.log(this.format(` ⚠️ ${message}`, 'orange'));
}
}
// Error display
error(message: string, file?: string, stack?: string) {
if (this.options.json) {