Commit 11522d2a authored by Ramya Authappan's avatar Ramya Authappan

Merge branch 'qa-e2e-improve-review-merge-request-spec' into 'master'

Improvements to make review_merge_request_spec more reliable

See merge request gitlab-org/gitlab!28974
parents f32af2d0 504a104a
...@@ -120,10 +120,12 @@ module QA ...@@ -120,10 +120,12 @@ module QA
def add_to_modified_content(content) def add_to_modified_content(content)
finished_loading? finished_loading?
modified_text_area.click
modified_text_area.set content modified_text_area.set content
end end
def modified_text_area def modified_text_area
wait_for_animated_element(:editor_container)
within_element(:editor_container) do within_element(:editor_container) do
find('.modified textarea.inputarea') find('.modified textarea.inputarea')
end end
......
...@@ -4,12 +4,13 @@ module QA ...@@ -4,12 +4,13 @@ module QA
context 'Create', quarantine: { type: :new } do context 'Create', quarantine: { type: :new } do
describe 'Review a merge request in Web IDE' do describe 'Review a merge request in Web IDE' do
let(:new_file) { 'awesome_new_file.txt' } let(:new_file) { 'awesome_new_file.txt' }
let(:original_text) { 'Text' }
let(:review_text) { 'Reviewed ' } let(:review_text) { 'Reviewed ' }
let(:merge_request) do let(:merge_request) do
Resource::MergeRequest.fabricate_via_api! do |mr| Resource::MergeRequest.fabricate_via_api! do |mr|
mr.file_name = new_file mr.file_name = new_file
mr.file_content = 'Text' mr.file_content = original_text
end end
end end
......
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