Implement comprehensive CalDAV calendar event parsing

Features:
- Complete CalendarEvent struct with all iCal properties
- EventStatus and EventClass enums for proper typing
- CalDAVClient for server communication with:
  - fetch_events() method using CalDAV REPORT queries
  - discover_calendars() with intelligent path discovery
  - Full iCal parsing using ical crate
  - DateTime parsing with multiple format support
  - XML response parsing with regex

Integration tests:
- Real server event fetching with calendar discovery
- iCal parsing validation with sample data
- DateTime parsing tests (UTC, local, date-only)
- Successful connection to configured calendar path

Dependencies added:
- regex crate for XML parsing
- Enhanced calendar module structure

Test results: ✓ All 7 tests pass
- Successfully connects to /calendars/test/ path
- Fetches 0 events (empty calendar, connection confirmed)
- No more 404 errors with improved discovery logic

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Connor Johnstone
2025-08-28 15:30:47 -04:00
parent 786f078e45
commit ad176dd423
3 changed files with 643 additions and 0 deletions

View File

@@ -36,5 +36,8 @@ uuid = { version = "1.0", features = ["v4", "wasm-bindgen"] }
dotenvy = "0.15"
base64 = "0.21"
# XML/Regex parsing
regex = "1.0"
[dev-dependencies]
tokio = { version = "1.0", features = ["macros", "rt"] }