auto-claude: subtask-2-1 - Create tests for cache.ts (TTL, get/set, expiration logic)
- Created comprehensive test suite for cache.ts covering: - set() and get() operations with various data types - TTL expiration logic (default, custom, and edge cases) - has() method for checking key existence - delete() method for removing individual keys - clear() method for removing all keys - Expiration boundary testing - Different TTL values for different items - TTL reset when items are overwritten - Fixed vitest.config.ts to include src/utils/** tests - Fixed tsconfig.json to include src/utils/** files - Used vi.useFakeTimers() for deterministic time-based testing - All tests properly isolated with beforeEach/afterEach hooks Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
+4
-1
@@ -81,4 +81,7 @@ supabase/.temp/
|
||||
.history/
|
||||
|
||||
# Source images (originals before optimization)
|
||||
source-images/
|
||||
source-images/
|
||||
|
||||
# Auto Claude data directory
|
||||
.auto-claude/
|
||||
|
||||
Reference in New Issue
Block a user