Commit dabf8a8d authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Merge branch 'fix-merge-request-diff-spinach-failures' into 'master'

Fix Spinach merge request diff failures

gitlab-git-test `master` was updated in ff076d88, and this caused the merge request diffs to change in a way that broke assumptions in the Spinach tests.
    
Partial fix to #23378

See merge request !6916
parents 11da7594 9e30b75e
......@@ -7,6 +7,7 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
include SharedMarkdown
include SharedDiffNote
include SharedUser
include WaitForAjax
step 'I click link "New Merge Request"' do
click_link "New Merge Request"
......@@ -90,6 +91,7 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
step 'I click button "Unsubscribe"' do
click_on "Unsubscribe"
wait_for_ajax
end
step 'I click link "Close"' do
......@@ -114,7 +116,7 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
source_project: project,
target_project: project,
source_branch: 'fix',
target_branch: 'master',
target_branch: 'merge-test',
author: project.users.first,
description: "# Description header"
)
......@@ -137,7 +139,8 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
title: "Bug NS-05",
source_project: project,
target_project: project,
author: project.users.first)
author: project.users.first,
source_branch: 'merge-test')
end
step 'project "Shop" have "Feature NS-05" merged merge request' do
......@@ -508,7 +511,7 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
step 'I should see new target branch changes' do
expect(page).to have_content 'Request to merge fix into feature'
expect(page).to have_content 'Target branch changed from master to feature'
expect(page).to have_content 'Target branch changed from merge-test to feature'
end
step 'I click on "Email Patches"' do
......
require Rails.root.join('features/support/wait_for_ajax')
module SharedNote
include Spinach::DSL
include WaitForAjax
step 'I delete a comment' do
page.within('.main-notes-list') do
......@@ -116,8 +119,9 @@ module SharedNote
page.within(".js-main-target-form") do
fill_in "note[note]", with: "# Comment with a header"
click_button "Comment"
sleep 0.05
end
wait_for_ajax
end
step 'The comment with the header should not have an ID' do
......
......@@ -17,6 +17,7 @@ module TestEnv
'markdown' => '0ed8c6c',
'lfs' => 'be93687',
'master' => 'b83d6e3',
'merge-test' => '5937ac0',
"'test'" => 'e56497b',
'orphaned-branch' => '45127a9',
'binary-encoding' => '7b1cf43',
......
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