Move investment partial to a component
This way we'll be able to simplify it a little bit. Note that the original partial didn't include the whole row and only the cells. Since, most of the time, we include the whole row in partials, we're slightly modifying the component.
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
require "rails_helper"
|
||||
|
||||
describe Admin::BudgetInvestments::RowComponent, :admin do
|
||||
it "uses a JSON request to update visible to valuators" do
|
||||
render_inline Admin::BudgetInvestments::RowComponent.new(create(:budget_investment))
|
||||
|
||||
expect(page).to have_css "form[action$='json'] input[name$='[visible_to_valuators]']"
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user