Sha256: befbb46f9c4f0760168112ea6a3d63fdfa57f0b89dfb3eb36ef8571bcac6b00a
Contents?: true
Size: 788 Bytes
Versions: 4
Compression:
Stored size: 788 Bytes
Contents
require 'spec_helper' describe <%= class_name %> do <% for attribute in attributes -%> it { should have_field(:<%= attribute.name %>).of_type(<%= attribute.type_class %>) } <% end -%> <% if child_model? -%> it {should <%= association_matcher %>(:<%=parent_name%>).as_inverse_of(:<%=parent_association%>)} <% end -%> <% if references_one -%> it {should reference_one(:<%=references_one%>)} <% end %> <% if references_many -%> it {should reference_many(:<%=references_many%>)} <% end %> <% if embeds_one -%> it {should embed_one(:<%=embeds_one%>)} <% end %> <% if embeds_many -%> it {should embed_many(:<%=embeds_many%>)} <% end %> end <% if child_model? -%> describe <%= parent_class %> do it {should <%= parent_association_matcher %>(:<%=parent_association%>)} end <% end -%>
Version data entries
4 entries across 4 versions & 1 rubygems