Merge pull request #1573 from consul/budgets-back-link
adds heading_id on investment show back link
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
|
||||
<div class="row">
|
||||
<div class="small-12 medium-9 column">
|
||||
<%= back_link_to budget_investments_path(investment.budget) %>
|
||||
<%= back_link_to budget_investments_path(heading_id: investment.heading.id) %>
|
||||
|
||||
<h1><%= investment.title %></h1>
|
||||
|
||||
|
||||
@@ -278,6 +278,13 @@ feature 'Budget Investments' do
|
||||
end
|
||||
end
|
||||
|
||||
scenario "Show back link contains heading id" do
|
||||
investment = create(:budget_investment, heading: heading)
|
||||
visit budget_investment_path(budget, investment)
|
||||
|
||||
expect(page).to have_link "Go back", href: budget_investments_path(budget, heading_id: heading.id)
|
||||
end
|
||||
|
||||
context "Show (feasible budget investment)" do
|
||||
let(:investment) { create(:budget_investment,
|
||||
:feasible,
|
||||
|
||||
Reference in New Issue
Block a user