Commit 5351fd39 authored by Kerri Miller's avatar Kerri Miller Committed by James Lopez

Remove support for `/wip` quick action [RUN ALL RSPEC] [RUN AS-IF-FOSS]

parent 9b466bb0
---
title: Remove support for /wip quick action
merge_request: 61199
author:
type: removed
......@@ -111,7 +111,6 @@ threads. Some quick actions might not be available to all subscription tiers.
| `/unlock` | **{check-circle}** Yes | **{check-circle}** Yes | **{dotted-circle}** No | Unlock the discussions. |
| `/unsubscribe` | **{check-circle}** Yes | **{check-circle}** Yes | **{check-circle}** Yes | Unsubscribe from notifications. |
| `/weight <value>` | **{check-circle}** Yes | **{dotted-circle}** No | **{dotted-circle}** No | Set weight. Valid options for `<value>` include `0`, `1`, `2`, and so on. |
| `/wip` | **{dotted-circle}** No | **{check-circle}** Yes | **{dotted-circle}** No | Toggle the draft status. |
| `/zoom <Zoom URL>` | **{check-circle}** Yes | **{dotted-circle}** No | **{dotted-circle}** No | Add Zoom meeting to this issue ([introduced in GitLab 12.4](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/16609)). |
## Commit messages
......
......@@ -99,7 +99,7 @@ module Gitlab
# Allow it to mark as WIP on MR creation page _or_ through MR notes.
(quick_action_target.new_record? || current_user.can?(:"update_#{quick_action_target.to_ability_name}", quick_action_target))
end
command :draft, :wip do
command :draft do
@updates[:wip_event] = quick_action_target.work_in_progress? ? 'unwip' : 'wip'
end
......
......@@ -82,7 +82,7 @@ RSpec.describe MergeRequests::CreateService, :clean_gitlab_redis_shared_state do
let(:opts) do
{
title: 'Awesome merge_request',
description: "well this is not done yet\n/wip",
description: "well this is not done yet\n/draft",
source_branch: 'feature',
target_branch: 'master',
assignees: [user2]
......
......@@ -307,7 +307,7 @@ RSpec.describe Notes::CreateService do
),
# Set WIP status
QuickAction.new(
action_text: "/wip",
action_text: "/draft",
before_action: -> {
issuable.reload.update!(title: "title")
},
......@@ -317,7 +317,7 @@ RSpec.describe Notes::CreateService do
),
# Remove WIP status
QuickAction.new(
action_text: "/wip",
action_text: "/draft",
before_action: -> {
issuable.reload.update!(title: "WIP: title")
},
......
......@@ -1201,16 +1201,6 @@ RSpec.describe QuickActions::InterpretService do
let(:issuable) { issue }
end
it_behaves_like 'draft command' do
let(:content) { '/wip' }
let(:issuable) { merge_request }
end
it_behaves_like 'undraft command' do
let(:content) { '/wip' }
let(:issuable) { merge_request }
end
it_behaves_like 'draft command' do
let(:content) { '/draft' }
let(:issuable) { merge_request }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment