Commit 710f5b3c authored by Peter Leitzen's avatar Peter Leitzen

Merge branch '32133-remove-feature-flag-for-zoom' into 'master'

Remove feature flag for zoom quick actions on issues

See merge request gitlab-org/gitlab!17787
parents 5d14ae13 bba1b3dd
...@@ -17,7 +17,7 @@ module Issues ...@@ -17,7 +17,7 @@ module Issues
end end
def can_add_link? def can_add_link?
available? && !link_in_issue_description? can? && !link_in_issue_description?
end end
def remove_link def remove_link
...@@ -29,7 +29,7 @@ module Issues ...@@ -29,7 +29,7 @@ module Issues
end end
def can_remove_link? def can_remove_link?
available? && link_in_issue_description? can? && link_in_issue_description?
end end
def parse_link(link) def parse_link(link)
...@@ -75,14 +75,6 @@ module Issues ...@@ -75,14 +75,6 @@ module Issues
issue_description[/(\S+)\z/, 1] issue_description[/(\S+)\z/, 1]
end end
def available?
feature_enabled? && can?
end
def feature_enabled?
Feature.enabled?(:issue_zoom_integration, project)
end
def can? def can?
current_user.can?(:update_issue, project) current_user.can?(:update_issue, project)
end end
......
---
title: Allow users to add and remove zoom rooms on an issue using quick action commands
merge_request:
author:
type: added
...@@ -64,8 +64,8 @@ The following quick actions are applicable to descriptions, discussions and thre ...@@ -64,8 +64,8 @@ The following quick actions are applicable to descriptions, discussions and thre
| `/create_merge_request <branch name>` | ✓ | | | Create a new merge request starting from the current issue | | `/create_merge_request <branch name>` | ✓ | | | Create a new merge request starting from the current issue |
| `/relate #issue1 #issue2` | ✓ | | | Mark issues as related **(STARTER)** | | `/relate #issue1 #issue2` | ✓ | | | Mark issues as related **(STARTER)** |
| `/move <path/to/project>` | ✓ | | | Move this issue to another project | | `/move <path/to/project>` | ✓ | | | Move this issue to another project |
| `/zoom <Zoom URL>` | ✓ | | | Add Zoom meeting to this issue. ([Introduced in GitLab 12.3](https://gitlab.com/gitlab-org/gitlab/merge_requests/16609). Must be enabled by feature flag `issue_zoom_integration` for self-hosted. [Feature flag to be removed and available by default in 12.4.](https://gitlab.com/gitlab-org/gitlab/issues/32133)) | | `/zoom <Zoom URL>` | ✓ | | | Add Zoom meeting to this issue. |
| `/remove_zoom` | ✓ | | | Remove Zoom meeting from this issue. ([Introduced in GitLab 12.3](https://gitlab.com/gitlab-org/gitlab/merge_requests/16609). Must be enabled by feature flag `issue_zoom_integration` for self-hosted. [Feature flag to be removed and available by default in 12.4.](https://gitlab.com/gitlab-org/gitlab/issues/32133)) | | `/remove_zoom` | ✓ | | | Remove Zoom meeting from this issue. |
| `/target_branch <local branch name>` | | ✓ | | Set target branch | | `/target_branch <local branch name>` | | ✓ | | Set target branch |
| `/wip` | | ✓ | | Toggle the Work In Progress status | | `/wip` | | ✓ | | Toggle the Work In Progress status |
| `/approve` | | ✓ | | Approve the merge request | | `/approve` | | ✓ | | Approve the merge request |
......
...@@ -38,12 +38,6 @@ describe Issues::ZoomLinkService do ...@@ -38,12 +38,6 @@ describe Issues::ZoomLinkService do
end end
end end
shared_context 'feature flag disabled' do
before do
stub_feature_flags(issue_zoom_integration: false)
end
end
shared_context 'insufficient permissions' do shared_context 'insufficient permissions' do
before do before do
project.add_guest(user) project.add_guest(user)
...@@ -78,11 +72,6 @@ describe Issues::ZoomLinkService do ...@@ -78,11 +72,6 @@ describe Issues::ZoomLinkService do
include_examples 'cannot add link' include_examples 'cannot add link'
end end
context 'when feature flag is disabled' do
include_context 'feature flag disabled'
include_examples 'cannot add link'
end
context 'with insufficient permissions' do context 'with insufficient permissions' do
include_context 'insufficient permissions' include_context 'insufficient permissions'
include_examples 'cannot add link' include_examples 'cannot add link'
...@@ -113,12 +102,6 @@ describe Issues::ZoomLinkService do ...@@ -113,12 +102,6 @@ describe Issues::ZoomLinkService do
it { is_expected.to eq(true) } it { is_expected.to eq(true) }
context 'when feature flag is disabled' do
include_context 'feature flag disabled'
it { is_expected.to eq(false) }
end
context 'with insufficient permissions' do context 'with insufficient permissions' do
include_context 'insufficient permissions' include_context 'insufficient permissions'
...@@ -152,11 +135,6 @@ describe Issues::ZoomLinkService do ...@@ -152,11 +135,6 @@ describe Issues::ZoomLinkService do
.to eq(issue.description.delete_suffix("\n\n#{zoom_link}")) .to eq(issue.description.delete_suffix("\n\n#{zoom_link}"))
end end
context 'when feature flag is disabled' do
include_context 'feature flag disabled'
include_examples 'cannot remove link'
end
context 'with insufficient permissions' do context 'with insufficient permissions' do
include_context 'insufficient permissions' include_context 'insufficient permissions'
include_examples 'cannot remove link' include_examples 'cannot remove link'
...@@ -187,12 +165,6 @@ describe Issues::ZoomLinkService do ...@@ -187,12 +165,6 @@ describe Issues::ZoomLinkService do
it { is_expected.to eq(true) } it { is_expected.to eq(true) }
context 'when feature flag is disabled' do
include_context 'feature flag disabled'
it { is_expected.to eq(false) }
end
context 'with insufficient permissions' do context 'with insufficient permissions' do
include_context 'insufficient permissions' include_context 'insufficient permissions'
......
...@@ -45,14 +45,6 @@ shared_examples 'zoom quick actions' do ...@@ -45,14 +45,6 @@ shared_examples 'zoom quick actions' do
expect(page).to have_content('Failed to add a Zoom meeting') expect(page).to have_content('Failed to add a Zoom meeting')
expect(page).not_to have_content(zoom_link) expect(page).not_to have_content(zoom_link)
end end
context 'when feature flag disabled' do
before do
stub_feature_flags(issue_zoom_integration: false)
end
include_examples 'skip silently'
end
end end
context 'with Zoom link not at the end of the issue description' do context 'with Zoom link not at the end of the issue description' do
...@@ -92,14 +84,6 @@ shared_examples 'zoom quick actions' do ...@@ -92,14 +84,6 @@ shared_examples 'zoom quick actions' do
expect(page).to have_content('Zoom meeting removed') expect(page).to have_content('Zoom meeting removed')
expect(issue.reload.description).to eq("Text with #{zoom_link}") expect(issue.reload.description).to eq("Text with #{zoom_link}")
end end
context 'when feature flag disabled' do
before do
stub_feature_flags(issue_zoom_integration: false)
end
include_examples 'skip silently'
end
end end
context 'with a Zoom link not at the end of the description' do context 'with a Zoom link not at the end of the description' do
......
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