require 'rails_helper'
require 'bh/core_ext/rails/form_for_helper'
include Bh::Rails::Helpers
describe 'fields_for' do
let(:protect_against_forgery?) { false }
let(:form) { form_for user, layout: layout, url: '/', &block }
let(:user) { User.new }
let(:layout) { :whatever }
let(:block) { Proc.new {|f| f.fields_for :address, options, &fields_block } }
let(:options) { {} }
let(:title) { nil }
let(:fields_block) { Proc.new {|f| f.text_field :street } }
describe 'with the :fieldset option' do
specify 'not set, wraps the fields in a