From 70099cbadaffceed27ef35164e520939608a8047 Mon Sep 17 00:00:00 2001 From: Jeremy Friesen Date: Wed, 20 Dec 2023 16:40:07 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=A7=B9=20Assigning=20collection=5Ftype?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The partials rendered in the tested view assume that we've set a collection type. --- .../views/hyrax/dashboard/collections/_form_share.erb_spec.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/spec/views/hyrax/dashboard/collections/_form_share.erb_spec.rb b/spec/views/hyrax/dashboard/collections/_form_share.erb_spec.rb index e81b615db..5ed7e31c3 100644 --- a/spec/views/hyrax/dashboard/collections/_form_share.erb_spec.rb +++ b/spec/views/hyrax/dashboard/collections/_form_share.erb_spec.rb @@ -8,10 +8,12 @@ to_key: template.to_key, access_grants: template.access_grants) end - let(:collection) { stub_model(Collection, share_applies_to_new_works?: false) } + let(:collection) { stub_model(Collection) } + let(:collection_type) { stub_model(Hyrax::CollectionType, share_applies_to_new_works?: false) } before do assign(:collection, collection) + assign(:collection_type, collection_type) @form = instance_double(Hyrax::Forms::CollectionForm, to_model: collection, permission_template: pt_form,