Skip to content

Migrate MultipleChoiceTaskFragment to use TaskScreen Component#3652

Open
shobhitagarwal1612 wants to merge 2 commits intomasterfrom
multiple-choice-compose-task
Open

Migrate MultipleChoiceTaskFragment to use TaskScreen Component#3652
shobhitagarwal1612 wants to merge 2 commits intomasterfrom
multiple-choice-compose-task

Conversation

@shobhitagarwal1612
Copy link
Copy Markdown
Member

Towards #3630

  • Introduce MultipleChoiceTaskScreen Composable to handle the UI.
  • Update MultipleChoiceTaskFragment to use createComposeView and render the new MultipleChoiceTaskScreen.
  • Replace MultipleChoiceTaskFragmentTest with MultipleChoiceTaskScreenTest and add more coverage

There is a pure refactor and doesn't cause any visual change.

@andreia-ferreira PTAL?

…screen

- Extract the multiple-choice task UI into a new `MultipleChoiceTaskScreen` Composable.
- Migrate `MultipleChoiceTaskFragment` to use `createComposeView`, integrating `MultipleChoiceTaskScreen` for rendering.
- Update the fragment to delegate action handling and footer position updates to the new screen component.
- Move the task body rendering logic from `MultipleChoiceTaskFragment` to `MultipleChoiceTaskContent`.
- Replace `MultipleChoiceTaskFragmentTest` with `MultipleChoiceTaskScreenTest`, migrating tests to use `composeTestRule`.
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 1, 2026

Codecov Report

❌ Patch coverage is 93.10345% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 66.72%. Comparing base (506ca77) to head (d57a6cc).

Files with missing lines Patch % Lines
...n/tasks/multiplechoice/MultipleChoiceTaskScreen.kt 91.66% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master    #3652      +/-   ##
============================================
- Coverage     66.80%   66.72%   -0.08%     
+ Complexity     1631     1625       -6     
============================================
  Files           362      363       +1     
  Lines          8939     8957      +18     
  Branches       1144     1147       +3     
============================================
+ Hits           5972     5977       +5     
- Misses         2320     2329       +9     
- Partials        647      651       +4     
Files with missing lines Coverage Δ
...tasks/multiplechoice/MultipleChoiceTaskFragment.kt 100.00% <100.00%> (+8.33%) ⬆️
...n/tasks/multiplechoice/MultipleChoiceTaskScreen.kt 91.66% <91.66%> (ø)

... and 5 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant