diff options
author | Bob Van Landuyt <bob@vanlanduyt.co> | 2017-09-21 19:34:32 +0300 |
---|---|---|
committer | Bob Van Landuyt <bob@vanlanduyt.co> | 2017-10-07 12:46:23 +0300 |
commit | 7c00b53812895970fdb00cf1d27b059bb15815cd (patch) | |
tree | 42ec37cf257cd11abd8469b6fb7921bc7f204043 /spec/features/merge_requests | |
parent | 70716a1292ca5910908ba37a9d113c8b5a221bb7 (diff) |
Find branches in all projects in the fork network
Diffstat (limited to 'spec/features/merge_requests')
-rw-r--r-- | spec/features/merge_requests/create_new_mr_from_fork_spec.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/spec/features/merge_requests/create_new_mr_from_fork_spec.rb b/spec/features/merge_requests/create_new_mr_from_fork_spec.rb index 515818c5d42..e6f827174e2 100644 --- a/spec/features/merge_requests/create_new_mr_from_fork_spec.rb +++ b/spec/features/merge_requests/create_new_mr_from_fork_spec.rb @@ -44,6 +44,25 @@ feature 'Creating a merge request from a fork', :js do expect { click_button 'Submit merge request' } .to change { target_project.merge_requests.reload.size }.by(1) end + + it 'updates the branches when selecting a new target project' do + target_project_member = target_project.owner + CreateBranchService.new(target_project, target_project_member) + .execute('a-brand-new-branch-to-test', 'master') + + visit project_new_merge_request_path(source_project) + + first('.js-target-project').click + find('.dropdown-target-project .dropdown-content a', text: target_project.full_path).click + + wait_for_requests + + first('.js-target-branch').click + + within('.dropdown-target-branch .dropdown-content') do + expect(page).to have_content('a-brand-new-branch-to-test') + end + end end context 'creating to the source of a fork' do |