Sha256: 9176c65feb9a50477f03a05a6d67d489a7ef878bdb71ad2d0ba99fced5cc1218
Contents?: true
Size: 614 Bytes
Versions: 6
Compression:
Stored size: 614 Bytes
Contents
class ShopLineItemsDataset < Dataset::Base uses :shop_products, :shop_orders def load create_record :shop_line_item, :one, :item_id => shop_products(:crusty_bread).id, :order => shop_orders(:one_item), :item_type => 'ShopProduct' create_record :shop_line_item, :two, :item_id => shop_products(:soft_bread).id, :order => shop_orders(:several_items), :item_type => 'ShopProduct', :quantity => 2 create_record :shop_line_item, :three, :item_id => shop_products(:choc_milk).id, :order => shop_orders(:several_items), :item_type => 'ShopProduct', :quantity => 3 end end
Version data entries
6 entries across 6 versions & 1 rubygems