From de14439ea4b7cc7e313af985ac6eaa95e4d0e8c3 Mon Sep 17 00:00:00 2001 From: Phil Hughes Date: Thu, 16 Mar 2017 12:04:51 +0000 Subject: Enabled remote filter in compare dropdowns Previously if the project had more than 100 branches or tags it wouldnt display them even after searching. This now correctly sends an AJAx request to the backend to search for the branches/tags Closes #29545 --- spec/features/projects/compare_spec.rb | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'spec/features/projects/compare_spec.rb') diff --git a/spec/features/projects/compare_spec.rb b/spec/features/projects/compare_spec.rb index 43eb4000e58..030043d14aa 100644 --- a/spec/features/projects/compare_spec.rb +++ b/spec/features/projects/compare_spec.rb @@ -26,6 +26,14 @@ describe "Compare", js: true do click_button "Compare" expect(page).to have_content "Commits" end + + it "filters branches" do + select_using_dropdown("from", "wip") + + find(".js-compare-from-dropdown .compare-dropdown-toggle").click + + expect(find(".js-compare-from-dropdown .dropdown-content")).to have_selector("li", count: 3) + end end describe "tags" do -- cgit v1.2.1