Commit 280a12cf authored by Heinrich Lee Yu's avatar Heinrich Lee Yu

Fix epics state filter path in group roadmap page

Includes `label_name` param
parent 47592691
...@@ -79,7 +79,7 @@ module EpicsHelper ...@@ -79,7 +79,7 @@ module EpicsHelper
end end
def epic_state_dropdown_link(state, selected_state) def epic_state_dropdown_link(state, selected_state)
link_to epic_state_title(state), page_filter_path(state: state), class: state == selected_state ? 'is-active' : '' link_to epic_state_title(state), page_filter_path(state: state, label: true), class: state == selected_state ? 'is-active' : ''
end end
def epic_state_title(state) def epic_state_title(state)
......
...@@ -126,6 +126,16 @@ describe 'group epic roadmap', :js do ...@@ -126,6 +126,16 @@ describe 'group epic roadmap', :js do
expect(page).to have_content(epic_with_bug.title) expect(page).to have_content(epic_with_bug.title)
end end
end end
it 'keeps label filter when filtering by state' do
state_dropdown.find('.dropdown-toggle').click
state_dropdown.find('a', text: 'Open epics').click
page.within('.roadmap-container .epics-list-section') do
expect(page).to have_selector('.epics-list-item .epic-title', count: 1)
expect(page).to have_content(epic_with_bug.title)
end
end
end end
end end
......
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