test(T2): add widget tests for ThreadDetailScreen and SearchScreen #31

Merged
guettlibot merged 1 commits from task/t2-widget-tests into main 2026-05-14 02:59:03 +00:00
guettlibot commented 2026-05-14 02:54:51 +00:00 (Migrated from codeberg.org)

Summary

  • Adds test/widget/thread_detail_screen_test.dart (6 tests) covering: empty-thread placeholder, sender display, default expansion of latest email, collapse on tap, star icon for flagged email, and plain text body rendering
  • Adds test/widget/search_screen_test.dart (6 tests) covering: initial placeholder, sub-3-char debounce guard, "No results" state, email results under "Messages" section, folder results under "Folders" section, and clear-button reset
  • Extends the shared helpers.dart test router with the ThreadDetailScreen route so tests can navigate to it by URL

Test plan

  • task check-fast passes (dart format + analyze + all widget/unit tests green)
  • Both new test files pass in isolation
## Summary - Adds `test/widget/thread_detail_screen_test.dart` (6 tests) covering: empty-thread placeholder, sender display, default expansion of latest email, collapse on tap, star icon for flagged email, and plain text body rendering - Adds `test/widget/search_screen_test.dart` (6 tests) covering: initial placeholder, sub-3-char debounce guard, "No results" state, email results under "Messages" section, folder results under "Folders" section, and clear-button reset - Extends the shared `helpers.dart` test router with the `ThreadDetailScreen` route so tests can navigate to it by URL ## Test plan - [x] `task check-fast` passes (dart format + analyze + all widget/unit tests green) - [x] Both new test files pass in isolation
Sign in to join this conversation.