4 Commits

Author SHA1 Message Date
jdb bf96303bf9 Update tests for BufferLogAppender and its utilities.
AI-Assisted: yes
AI-Tool: OpenAI Codex / gpt-5.5 xhigh
2026-05-07 07:37:00 -05:00
mahseiah_ai ebcd7880fb feat: add buffer max to buffer appender 2026-05-07 07:37:00 -05:00
mahseiah_ai 9ebac95c27 test: add comprehensive unit tests for all appenders and logger
Tests added:
- log-service.test.ts: hierarchical logger creation and threshold propagation
- logger.test.ts: threshold inheritance, message propagation, falsy threshold
  bug coverage (LogLevel.ALL = 0), deferred messages, Error handling
- log-message.test.ts: parseLogLevel parsing, flattenMessage object/string modes
- console-log-appender.test.ts: threshold, formatter, all-level routing
- buffer-log-appender.test.ts: buffer append, threshold filtering, clearBuffer
- api-log-appender.test.ts: configuration defaults, threshold, auth token

Also fixes src/index.ts to export BufferLogAppender which was previously
missing from the barrel export.
2026-05-07 07:37:00 -05:00
mahseiah_ai c957150879 test: stand up test scaffolding with bun test
- Create test/ directory with a minimal LogService test
- Prove out the pattern: bun test natively discovers and runs tests
  in the test/ directory using ESM-style imports from ../src/
2026-05-07 07:37:00 -05:00