summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Speicher <rspeicher@gmail.com>2019-04-09 10:17:57 +0000
committerRobert Speicher <rspeicher@gmail.com>2019-04-09 10:17:57 +0000
commit7b0f9f82f65dc62d451c962a9d3f6a18b4572415 (patch)
tree1346de937a016420a8a5e6baf4b93088b7cde464
parent7e22054a361a33f65a7bd5c544a41642841dcb64 (diff)
parent4e95aa3de59220d32211f608f66400a1f067d77a (diff)
downloadgitlab-ce-7b0f9f82f65dc62d451c962a9d3f6a18b4572415.tar.gz
Merge branch '6573-extract-ee-spec-features-boards-ce' into 'master'
CE: Resolve "Extract EE specific files/lines for spec/features/boards" See merge request gitlab-org/gitlab-ce!27110
-rw-r--r--spec/features/boards/sidebar_spec.rb2
-rw-r--r--spec/support/helpers/filtered_search_helpers.rb6
2 files changed, 8 insertions, 0 deletions
diff --git a/spec/features/boards/sidebar_spec.rb b/spec/features/boards/sidebar_spec.rb
index dfdb8d589eb..b358c6b9c34 100644
--- a/spec/features/boards/sidebar_spec.rb
+++ b/spec/features/boards/sidebar_spec.rb
@@ -2,6 +2,7 @@ require 'rails_helper'
describe 'Issue Boards', :js do
include BoardHelpers
+ include FilteredSearchHelpers
let(:user) { create(:user) }
let(:user2) { create(:user) }
@@ -129,6 +130,7 @@ describe 'Issue Boards', :js do
click_link 'Unassigned'
end
+ close_dropdown_menu_if_visible
wait_for_requests
expect(page).to have_content('No assignee')
diff --git a/spec/support/helpers/filtered_search_helpers.rb b/spec/support/helpers/filtered_search_helpers.rb
index 6569feec39b..03057a102c5 100644
--- a/spec/support/helpers/filtered_search_helpers.rb
+++ b/spec/support/helpers/filtered_search_helpers.rb
@@ -149,4 +149,10 @@ module FilteredSearchHelpers
loop until find('.filtered-search').value.strip == text
end
end
+
+ def close_dropdown_menu_if_visible
+ find('.dropdown-menu-toggle', visible: :all).tap do |toggle|
+ toggle.click if toggle.visible?
+ end
+ end
end