Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/features/merge_request/user_sees_wip_help_message_spec.rb')
-rw-r--r--spec/features/merge_request/user_sees_wip_help_message_spec.rb61
1 files changed, 0 insertions, 61 deletions
diff --git a/spec/features/merge_request/user_sees_wip_help_message_spec.rb b/spec/features/merge_request/user_sees_wip_help_message_spec.rb
deleted file mode 100644
index fdefe5ffb06..00000000000
--- a/spec/features/merge_request/user_sees_wip_help_message_spec.rb
+++ /dev/null
@@ -1,61 +0,0 @@
-# frozen_string_literal: true
-
-require 'spec_helper'
-
-RSpec.describe 'Merge request > User sees draft help message', feature_category: :code_review_workflow do
- let(:project) { create(:project, :public, :repository) }
- let(:user) { project.creator }
-
- before do
- project.add_maintainer(user)
- sign_in(user)
- end
-
- context 'with draft commits' do
- it 'shows a specific draft hint' do
- visit project_new_merge_request_path(
- project,
- merge_request: {
- source_project_id: project.id,
- target_project_id: project.id,
- source_branch: 'wip',
- target_branch: 'master'
- })
-
- within_wip_explanation do
- expect(page).to have_text(
- 'It looks like you have some draft commits in this branch'
- )
- end
- end
- end
-
- context 'without draft commits' do
- it 'shows the regular draft message' do
- visit project_new_merge_request_path(
- project,
- merge_request: {
- source_project_id: project.id,
- target_project_id: project.id,
- source_branch: 'fix',
- target_branch: 'master'
- })
-
- within_wip_explanation do
- expect(page).not_to have_text(
- 'It looks like you have some draft commits in this branch'
- )
- expect(page).to have_text(
- "Start the title with Draft: to prevent a merge request draft \
-from merging before it's ready."
- )
- end
- end
- end
-
- def within_wip_explanation(&block)
- page.within '.js-no-wip-explanation' do
- yield
- end
- end
-end