Merge pull request #2058 from consul/booth-shifts-back

Booth shifts back link
This commit is contained in:
Raimond Garcia
2017-10-16 10:48:56 +02:00
committed by GitHub
2 changed files with 15 additions and 1 deletions

View File

@@ -1,4 +1,4 @@
<%= back_link_to admin_booths_path %>
<%= back_link_to available_admin_booths_path %>
<h2><%= @booth.name %></h2>

View File

@@ -113,4 +113,18 @@ feature 'Admin booths' do
end
end
scenario "Back link go back to available list when manage shifts" do
poll = create(:poll, :current)
booth = create(:poll_booth)
assignment = create(:poll_booth_assignment, poll: poll, booth: booth)
visit available_admin_booths_path
within("#booth_#{booth.id}") do
click_link "Manage shifts"
end
click_link "Go back"
expect(current_path).to eq(available_admin_booths_path)
end
end