Commit 400a1ae0 authored by Arinde Eniola's avatar Arinde Eniola

add some changes to the test

parent 451314df
require 'spec_helper' require 'spec_helper'
feature 'Create New Merge Request', feature: true do feature 'Edit Merge Request', feature: true do
let(:user) { create(:user) } let(:user) { create(:user) }
let(:project) { create(:project, :public) } let(:project) { create(:project, :public) }
let(:merge_request) { create(:merge_request, :with_diffs, source_project: project) } let(:merge_request) { create(:merge_request, :with_diffs, source_project: project) }
...@@ -13,15 +13,9 @@ feature 'Create New Merge Request', feature: true do ...@@ -13,15 +13,9 @@ feature 'Create New Merge Request', feature: true do
visit edit_namespace_project_merge_request_path(project.namespace, project, merge_request) visit edit_namespace_project_merge_request_path(project.namespace, project, merge_request)
end end
context 'editing a MR', js: true do context 'editing a MR' do
it 'should be able submit with quick_submit' do it 'form should have class js-quick-submit' do
fill_in "merge_request_title", with: "Orphaned MR test" expect(page).to have_selector('.js-quick-submit')
keypress = "var e = $.Event('keydown', { keyCode: 13, ctrlKey: true }); $('.merge-request-form').trigger(e);"
page.driver.execute_script(keypress)
sleep 2
expect(find('h2.title')).to have_text('Orphaned MR test')
end end
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