Remove redundant test to vote an investment
This is already tested in the "Add an investment" test.
This commit is contained in:
@@ -103,15 +103,17 @@ describe "Ballots" do
|
||||
end
|
||||
|
||||
context "Adding and Removing Investments" do
|
||||
scenario "Add a investment" do
|
||||
scenario "Add an investment" do
|
||||
create(:budget_investment, :selected, heading: new_york, price: 10000, title: "Bring back King Kong")
|
||||
create(:budget_investment, :selected, heading: new_york, price: 20000, title: "Paint cabs black")
|
||||
|
||||
visit budget_investments_path(budget, heading_id: new_york)
|
||||
add_to_ballot("Bring back King Kong")
|
||||
|
||||
expect(page).to have_css("#total_amount", text: "€10,000")
|
||||
expect(page).to have_css("#amount_available", text: "€990,000")
|
||||
within("#progress_bar") do
|
||||
expect(page).to have_css("#total_amount", text: "€10,000")
|
||||
expect(page).to have_css("#amount_available", text: "€990,000")
|
||||
end
|
||||
|
||||
within("#sidebar") do
|
||||
expect(page).to have_content "Bring back King Kong"
|
||||
@@ -268,18 +270,6 @@ describe "Ballots" do
|
||||
expect(page).to have_content("You have active votes in another heading: District 1")
|
||||
end
|
||||
end
|
||||
|
||||
scenario "Display progress bar after first vote" do
|
||||
create(:budget_investment, :selected, heading: new_york, price: 10000, title: "Park expansion")
|
||||
|
||||
visit budget_investments_path(budget, heading_id: new_york.id)
|
||||
|
||||
add_to_ballot("Park expansion")
|
||||
|
||||
within("#progress_bar") do
|
||||
expect(page).to have_css("#total_amount", text: "€10,000")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
context "Groups" do
|
||||
|
||||
Reference in New Issue
Block a user