Fix loading branches list on cherry pick modal after merge.
This commit is contained in:
parent
f3a3bd50ea
commit
de3eabc5bf
2 changed files with 14 additions and 0 deletions
|
@ -1,3 +1,4 @@
|
||||||
|
import Project from '~/project';
|
||||||
import SmartInterval from '~/smart_interval';
|
import SmartInterval from '~/smart_interval';
|
||||||
import Flash from '../flash';
|
import Flash from '../flash';
|
||||||
import {
|
import {
|
||||||
|
@ -140,6 +141,7 @@ export default {
|
||||||
const el = document.createElement('div');
|
const el = document.createElement('div');
|
||||||
el.innerHTML = res.body;
|
el.innerHTML = res.body;
|
||||||
document.body.appendChild(el);
|
document.body.appendChild(el);
|
||||||
|
Project.initRefSwitcher();
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
|
|
|
@ -63,6 +63,18 @@ describe 'Merge request', :js do
|
||||||
expect(page).to have_selector('.accept-merge-request')
|
expect(page).to have_selector('.accept-merge-request')
|
||||||
expect(find('.accept-merge-request')['disabled']).not_to be(true)
|
expect(find('.accept-merge-request')['disabled']).not_to be(true)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
it 'allows me to merge, see cherry-pick modal and load branches list' do
|
||||||
|
wait_for_requests
|
||||||
|
click_button 'Merge'
|
||||||
|
|
||||||
|
wait_for_requests
|
||||||
|
click_link 'Cherry-pick'
|
||||||
|
page.find('.js-project-refs-dropdown').click
|
||||||
|
wait_for_requests
|
||||||
|
|
||||||
|
expect(page.all('.js-cherry-pick-form .dropdown-content li').size).to be > 1
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
context 'view merge request with external CI service' do
|
context 'view merge request with external CI service' do
|
||||||
|
|
Loading…
Reference in a new issue