Sha256: bc3a53658a11c3f81913110567611a5aa076106e3fb8b8fd50959191c556192e
Contents?: true
Size: 1.41 KB
Versions: 11
Compression:
Stored size: 1.41 KB
Contents
# Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html <% unless attributes.empty? && belongs_tos.empty? -%> <%= class_name.underscore -%>_one: id: <%%= Fixtures.identify(:<%= class_name.underscore %>_one) %> <% for attribute in attributes -%> <%= attribute.name %>: <%= attribute.default("#{class_name}1") %> <% end -%> <% for model in belongs_tos -%> <%= model %>_id: <%%= Fixtures.identify(:<%= model %>_one) %> <% end -%> <%= class_name.underscore -%>_two: id: <%%= Fixtures.identify(:<%= class_name.underscore %>_two) %> <% for attribute in attributes -%> <%= attribute.name %>: <%= attribute.default("#{class_name}2") %> <% end -%> <% for model in belongs_tos -%> <%= model %>_id: <%%= Fixtures.identify(:<%= model %>_two) %> <% end -%> <%= class_name.underscore -%>_three: id: <%%= Fixtures.identify(:<%= class_name.underscore %>_three) %> <% for attribute in attributes -%> <%= attribute.name %>: <%= attribute.default("#{class_name}3") %> <% end -%> <% for model in belongs_tos -%> <%= model %>_id: <%%= Fixtures.identify(:<%= model %>_three) %> <% end -%> <%= class_name.underscore -%>_four: id: <%%= Fixtures.identify(:<%= class_name.underscore %>_four) %> <% for attribute in attributes -%> <%= attribute.name %>: <%= attribute.default("#{class_name}4") %> <% end -%> <% for model in belongs_tos -%> <%= model %>_id: <%%= Fixtures.identify(:<%= model %>_four) %> <% end -%> <% end -%>
Version data entries
11 entries across 11 versions & 4 rubygems