Sha256: 569654d7c60eb7a810f84829fc2a89910490f5e4517b2d23bc3e6420e6779fc7
Contents?: true
Size: 735 Bytes
Versions: 2
Compression:
Stored size: 735 Bytes
Contents
require 'spec_helper' describe WorkOrderItem do it "can be instantiated" do WorkOrderItem.new.should be_an_instance_of(WorkOrderItem) end it "can be saved successfully" do WorkOrderItem.create().should be_persisted end it "WorkOrderItem acts_as_order_line_item" do woi = WorkOrderItem.new woi.save woi.should be_an_instance_of(WorkOrderItem) woi.should be_persisted # test creation of OrderLineItem woi.order_line_item.should be_an_instance_of(OrderLineItem) woi.order_line_item.should be_persisted # test destruction of OrderLineItem order_line_item_id = woi.order_line_item.id woi.destroy WorkOrderItem.where(:id => order_line_item_id).should_not exist end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
erp_work_effort-4.2.0 | spec/models/work_order_item_spec.rb |
erp_work_effort-4.0.0 | spec/models/work_order_item_spec.rb |