1.0.0 Release

This commit is contained in:
Jerico Thomas
2025-07-25 15:31:22 -04:00
parent 6c5f8c399e
commit 805524b78c
19 changed files with 1323 additions and 95 deletions

42
tests/test_logging.py Normal file
View File

@@ -0,0 +1,42 @@
#!/usr/bin/env python3
"""
Test script to verify logging is working correctly
"""
import sys
import os
import time
sys.path.insert(0, '/Users/JeThomas/scripts/HereIAm/src')
from logging_config import setup_logging, get_logger
from config_manager import ConfigManager
def test_logging():
print("Testing logging system...")
# Test 1: Default logging setup
setup_logging()
logger = get_logger("test_logger")
logger.info("Test message 1 - Default setup")
logger.debug("This debug message should NOT appear in default setup")
# Test 2: Debug mode
print("\nSwitching to DEBUG mode...")
setup_logging(debug=True, force_reconfigure=True)
logger.info("Test message 2 - Debug mode")
logger.debug("This debug message SHOULD appear in debug mode")
# Test 3: Load config and apply logging
print("\nTesting with config manager...")
cm = ConfigManager()
config = cm.load_config()
debug_mode = config.get('log_level', 'INFO').upper() == 'DEBUG'
setup_logging(debug=debug_mode, force_reconfigure=True)
logger.info(f"Test message 3 - Config mode (debug={debug_mode})")
logger.debug(f"Debug message based on config: log_level={config.get('log_level', 'INFO')}")
print(f"\nCheck the log file at: ~/logs/hereiam.log")
print("Also check console output above for debug messages")
if __name__ == "__main__":
test_logging()