Commit 777273d
Add CLI tool and test infrastructure with real SQLite fixtures
- Create ctm-cli binary for debugging (JTAG-style access to internals)
- list-chats: List all iMessage chats with contact resolution
- contacts: Show contacts index statistics
- check-access: Verify Full Disk Access permission
- Add FactoryBot-style test data builders (test_fixtures module)
- TestIMessageDb: Creates in-memory iMessage database with real schema
- TestAddressBookDb: Creates in-memory AddressBook database with real schema
- Builders: HandleBuilder, ChatBuilder, MessageBuilder, ContactBuilder
- Set up fixtures/schemas/ with versioned database schemas
- imessage_26.0.1.sql: Real iMessage database schema
- addressbook_26.0.1.sql: Real AddressBook database schema
- scripts/update-schemas.sh: Schema dump/diff/version script
- Fix deduped_id vs handle_id bug in resolve_chat_display_name
- Handle::dedupe creates NEW sequential IDs, not identity mapping
- Added deduped_handles parameter to translate before lookup
- Refactor: Extract shared code into lib.rs, simplify main.rs
28 tests passing (14 unit + 8 integration + 6 fixture tests)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>1 parent a6a8290 commit 777273d
File tree
16 files changed
+2018
-251
lines changed- src-tauri
- fixtures/schemas
- scripts
- src
- test_fixtures
16 files changed
+2018
-251
lines changedSome generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
16 | | - | |
| 15 | + | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
22 | 23 | | |
23 | 24 | | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
27 | 41 | | |
28 | | - | |
29 | | - | |
| 42 | + | |
| 43 | + | |
30 | 44 | | |
31 | 45 | | |
32 | 46 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
3 | 6 | | |
0 commit comments