Skip to content

Commit

Permalink
Removed marked complete task action (#15211)
Browse files Browse the repository at this point in the history
Resolves #14869 

### Description
Added new action deletion method to remove "Mark Task Complete".

### Acceptance Criteria
- [ ] BvaDispatchTasks cannot be marked complete by anyone through the caseflow task action dropdown

### Testing Plan
1. Sign in as BVADispatch user White.
2. Navigate to your queue.
3. Select a case.
4. Confirm the action is not there.
5. Sign in as BVADispatch admin Black.
6. Navigate to the team assigned queue.
7. Repeat steps 3. and 4.
  • Loading branch information
mkerns355 authored Sep 11, 2020
1 parent b9b7da6 commit a92d878
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/models/tasks/bva_dispatch_task.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ def available_actions(user)
if assigned_to == user || parent.task_is_assigned_to_organization_user_administers?(user)
actions.unshift(Constants.TASK_ACTIONS.DISPATCH_RETURN_TO_JUDGE.to_h)
actions.delete(Constants.TASK_ACTIONS.ASSIGN_TO_TEAM.to_h)
actions.delete(Constants.TASK_ACTIONS.MARK_COMPLETE.to_h)
end

actions
Expand Down
5 changes: 5 additions & 0 deletions spec/models/tasks/bva_dispatch_task_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -237,5 +237,10 @@
expect(bva_d_task.available_actions(bva_d_task.assigned_to))
.not_to include(Constants.TASK_ACTIONS.ASSIGN_TO_TEAM.to_h)
end

it "actions should not include 'Mark Task Complete'" do
expect(bva_d_task.available_actions(bva_d_task.assigned_to))
.not_to include(Constants.TASK_ACTIONS.MARK_COMPLETE.to_h)
end
end
end

0 comments on commit a92d878

Please sign in to comment.