Sha256: 1402bf05a8623cac654fbeb6eae1e9caaca03a6c9560afe76b73a7774470be0f
Contents?: true
Size: 821 Bytes
Versions: 4
Compression:
Stored size: 821 Bytes
Contents
# -*- encoding: utf-8 -*- require 'spec_helper' describe OrderList do fixtures :all it "should calculate total price" do order_list = order_lists(:order_list_00001) order_list.total_price.should eq 0 order_list.purchase_requests << purchase_requests(:purchase_request_00006) order_list.total_price.should eq purchase_requests(:purchase_request_00006).price end end # == Schema Information # # Table name: order_lists # # id :integer not null, primary key # user_id :integer not null # bookstore_id :integer not null # title :text not null # note :text # ordered_at :datetime # deleted_at :datetime # state :string(255) # created_at :datetime not null # updated_at :datetime not null #
Version data entries
4 entries across 4 versions & 1 rubygems