Sha256: be451395c417e6d8950fb8b12e4969a7afa9dd9927cda897f1b24287354e5dec
Contents?: true
Size: 702 Bytes
Versions: 53
Compression:
Stored size: 702 Bytes
Contents
require 'rails_helper' describe Pulitzer::CreatePartialContentElements do let(:post_type) { pt = create(:post_type, :with_content_elements) pt.update_columns(kind: Pulitzer::PostType.kinds[:partial]) pt } let(:free_form_section) { Pulitzer::FreeFormSection.create name: 'test'} let(:partial) { free_form_section.partials.create(post_type_id: post_type.id) } it 'Copies content elements to preview version' do expect(post_type.post_type_content_element_types.size).to eq 3 expect(partial.content_elements.size).to eq 0 Pulitzer::CreatePartialContentElements.new(partial).call expect(partial.content_elements.size).to eq 3 end end
Version data entries
53 entries across 53 versions & 1 rubygems