You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Allow users to delete a task from the Task Detail screen by tapping the "Delete" button. Since deletion is destructive and irreversible, a confirmation dialog must be shown before the task is actually deleted.
The confirmation dialog should clearly state what will be deleted and offer two actions: "Delete" (destructive, confirms) and "Cancel" (dismisses the dialog). Upon confirmation, the task is removed from the repository and the user is navigated back to the previous screen.
In scope: delete confirmation dialog, task deletion from the repository, navigation back after deletion, and string resources.
Out of scope: undo/restore deleted task, swipe-to-delete (separate ticket), batch deletion.
Acceptance criteria
GIVEN the user is on the Task Detail screen
WHEN they tap the "Delete" button
THEN a confirmation dialog is shown
GIVEN the confirmation dialog is shown
WHEN the dialog renders
THEN it clearly states that the task will be permanently deleted
GIVEN the confirmation dialog is shown
WHEN the user taps "Cancel"
THEN the dialog is dismissed and the task is not deleted
GIVEN the confirmation dialog is shown
WHEN the user taps "Delete"
THEN the task is removed from the repository and the user is navigated back to the previous screen
GIVEN the user has confirmed deletion
WHEN they return to the previous screen
THEN the deleted task is no longer visible in the task list
GIVEN user-visible text appears in the confirmation dialog
WHEN the app renders the dialog
THEN all visible text comes from string resources
Activity