Commit b1d07760 authored by Phil Hughes's avatar Phil Hughes

Fixed search specs

Clean up the events when the modal window is closed
parent 3e95bd97
......@@ -15,7 +15,8 @@ export default {
this.filteredSearch = new FilteredSearchBoards(this.store, false);
},
destroyed() {
beforeDestroy() {
this.filteredSearch.cleanup();
FilteredSearchContainer.container = document;
this.store.path = '';
},
......
......@@ -421,7 +421,8 @@
display: flex;
.issues-filters {
width: 100%;
-webkit-flex: 1;
flex: 1;
}
}
......
......@@ -107,6 +107,7 @@ describe 'Issue Boards add issue modal', :feature, :js do
it 'returns issues' do
page.within('.add-issues-modal') do
find('.form-control').native.send_keys(issue.title)
find('.form-control').native.send_keys(:enter)
expect(page).to have_selector('.card', count: 1)
end
......@@ -115,6 +116,7 @@ describe 'Issue Boards add issue modal', :feature, :js do
it 'returns no issues' do
page.within('.add-issues-modal') do
find('.form-control').native.send_keys('testing search')
find('.form-control').native.send_keys(:enter)
expect(page).not_to have_selector('.card')
expect(page).not_to have_content("You haven't added any issues to your project yet")
......
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