Files
aiturk-mobil/app/src/test/java/com
M57 529ab0bc83 🧪 Add unit tests for ChatViewModel attachment manipulation (#511)
* Add unit tests for ChatViewModel attachment manipulation

Adds tests covering addAttachment, removeAttachment (valid/invalid indices),
and clearAttachments in ChatViewModelTest. This ensures the attachment
state management logic works as expected.

* test(#511): add mixed valid/invalid remove sequence + DRY attachment setup

Folds in both Sourcery review notes:
- New testRemoveAttachment_mixedValidAndInvalidSequence asserts list
  stays consistent across a valid remove, out-of-bounds + negative no-ops,
  then another valid remove on the shifted list.
- addDummyAttachments() helper removes repeated VM/advance/add boilerplate.

Verified: ktlintCheck clean + ChatViewModelTest 37/37 pass locally.
2026-07-09 15:49:34 +03:00
..