Fix crash in management with successful proposals
The page was crashing because it was looking for the `supports` partial under `management/proposals`, when the right path was `proposals/`.
This commit is contained in:
@@ -22,7 +22,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<% elsif proposal.successful? %>
|
<% elsif proposal.successful? %>
|
||||||
<div class="supports text-center">
|
<div class="supports text-center">
|
||||||
<%= render "supports", proposal: proposal %>
|
<%= render "proposals/supports", proposal: proposal %>
|
||||||
</div>
|
</div>
|
||||||
<% elsif proposal.archived? %>
|
<% elsif proposal.archived? %>
|
||||||
<div class="padding text-center">
|
<div class="padding text-center">
|
||||||
|
|||||||
@@ -75,6 +75,15 @@ describe "Proposals" do
|
|||||||
expect(page).not_to have_current_path(old_path)
|
expect(page).not_to have_current_path(old_path)
|
||||||
expect(page).to have_current_path(right_path)
|
expect(page).to have_current_path(right_path)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
scenario "Successful proposal", :js do
|
||||||
|
proposal = create(:proposal, :successful, title: "Success!")
|
||||||
|
|
||||||
|
login_managed_user(create(:user, :level_two))
|
||||||
|
visit management_proposal_path(proposal)
|
||||||
|
|
||||||
|
expect(page).to have_content("Success!")
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
scenario "Searching" do
|
scenario "Searching" do
|
||||||
|
|||||||
Reference in New Issue
Block a user