diff options
author | blackst0ne <blackst0ne.ru@gmail.com> | 2018-05-08 21:44:32 +0000 |
---|---|---|
committer | Robert Speicher <robert@gitlab.com> | 2018-05-08 21:44:32 +0000 |
commit | 3cb98379b6d668ba54777239272f8e2fe6f98fca (patch) | |
tree | 26e2ff321e30ddcd64a827f63a82b90bce34c150 /features/steps | |
parent | ee9d4386fd3081510f4d2c5a43bbed39907a7103 (diff) | |
download | gitlab-ce-3cb98379b6d668ba54777239272f8e2fe6f98fca.tar.gz |
Replace the `project/ff_merge_requests.feature` spinach test with an rspec analog
Diffstat (limited to 'features/steps')
-rw-r--r-- | features/steps/project/ff_merge_requests.rb | 87 | ||||
-rw-r--r-- | features/steps/shared/paths.rb | 5 |
2 files changed, 0 insertions, 92 deletions
diff --git a/features/steps/project/ff_merge_requests.rb b/features/steps/project/ff_merge_requests.rb deleted file mode 100644 index 27efcfd65b6..00000000000 --- a/features/steps/project/ff_merge_requests.rb +++ /dev/null @@ -1,87 +0,0 @@ -class Spinach::Features::ProjectFfMergeRequests < Spinach::FeatureSteps - include SharedAuthentication - include SharedIssuable - include SharedProject - include SharedNote - include SharedPaths - include SharedMarkdown - include SharedDiffNote - include SharedUser - include WaitForRequests - - step 'project "Shop" have "Bug NS-05" open merge request with diffs inside' do - create(:merge_request_with_diffs, - title: "Bug NS-05", - source_project: project, - target_project: project, - author: project.users.first) - end - - step 'merge request is mergeable' do - expect(page).to have_button 'Merge' - end - - step 'I should see ff-only merge button' do - expect(page).to have_content "Fast-forward merge without a merge commit" - expect(page).to have_button 'Merge' - end - - step 'merge request "Bug NS-05" is mergeable' do - merge_request.mark_as_mergeable - end - - step 'I accept this merge request' do - page.within '.mr-state-widget' do - click_button "Merge" - end - end - - step 'I should see merged request' do - page.within '.status-box' do - expect(page).to have_content "Merged" - wait_for_requests - end - end - - step 'ff merge enabled' do - project = merge_request.target_project - project.merge_requests_ff_only_enabled = true - project.save! - end - - step 'I should see rebase button' do - expect(page).to have_button "Rebase" - end - - step 'merge request "Bug NS-05" is rebased' do - merge_request.source_branch = 'flatten-dir' - merge_request.target_branch = 'improve/awesome' - merge_request.reload_diff - merge_request.save! - end - - step 'merge request "Bug NS-05" merged target' do - merge_request.source_branch = 'merged-target' - merge_request.target_branch = 'improve/awesome' - merge_request.reload_diff - merge_request.save! - end - - step 'rebase before merge enabled' do - project = merge_request.target_project - project.merge_requests_rebase_enabled = true - project.save! - end - - step 'I press rebase button' do - click_button "Rebase" - end - - step "I should see rebase in progress message" do - expect(page).to have_content("Rebase in progress") - end - - def merge_request - @merge_request ||= MergeRequest.find_by!(title: "Bug NS-05") - end -end diff --git a/features/steps/shared/paths.rb b/features/steps/shared/paths.rb index b6c648a707d..f2769f28fed 100644 --- a/features/steps/shared/paths.rb +++ b/features/steps/shared/paths.rb @@ -336,11 +336,6 @@ module SharedPaths wait_for_requests end - step 'I visit merge request page "Bug NS-05"' do - visit merge_request_path("Bug NS-05") - wait_for_requests - end - step 'I visit merge request page "Bug NS-07"' do visit merge_request_path("Bug NS-07") wait_for_requests |