Sha256: 2e6157a0db008c0b34cc9736d5521259eae972ed76187e0508c806aea6c23328
Contents?: true
Size: 1.62 KB
Versions: 2
Compression:
Stored size: 1.62 KB
Contents
require 'spec_helper' describe 'collections/_form.html.erb', :type => :view do describe 'when the collection edit form is rendered' do let(:collection) { Collection.new({title: 'the title', description: 'the description', creator: 'the creator'})} before do controller.request.path_parameters[:id] = 'j12345' collection.initialize_fields assign(:collection, collection) end it "should draw the metadata fields for collection" do render expect(rendered).to have_selector("input#collection_title", count: 1) expect(rendered).to have_selector("input#collection_creator", count: 1) expect(rendered).to have_selector("textarea#collection_description", count: 1) expect(rendered).to have_selector("input#collection_contributor", count: 1) expect(rendered).to have_selector("input#collection_tag", count: 1) expect(rendered).to have_selector("input#collection_subject", count: 1) expect(rendered).to have_selector("input#collection_publisher", count: 1) expect(rendered).to have_selector("input#collection_date_created", count: 1) expect(rendered).to have_selector("input#collection_language", count: 1) expect(rendered).to have_selector("input#collection_identifier", count: 1) expect(rendered).to have_selector("input#collection_based_near", count: 1) expect(rendered).to have_selector("input#collection_related_url", count: 1) expect(rendered).to have_selector("select#collection_rights", count: 1) expect(rendered).to have_selector("select#collection_resource_type", count: 1) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
sufia-5.0.0 | spec/views/collections/_form.html.erb_spec.rb |
sufia-5.0.0.rc1 | spec/views/collections/_form.html.erb_spec.rb |