unidom-shipment 0.7.5 → 0.7.6
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d150e30d5110189490cb09fd64b6f21af71bb4fb
|
4
|
+
data.tar.gz: 2ecf7d46ec4776b5cd67f0e9ad52726c03e075cc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: '09a47997a7f3bb5064c51c127e53ff74f3ec51a54f309d79378feed4190890ef698aa0c47681de6a751c09dbaca492c1f846875da6d362326b7e1e356274209d'
|
7
|
+
data.tar.gz: 16852ac248374391851ced2991b1f7729abe5bb4d1b05e595933a2a1f534898e7c28c1b0440d9729c6350594411efa129fd201c0ce6f7c7629c05fdc5b0973db
|
@@ -52,6 +52,18 @@ describe Unidom::Shipment::ShipmentItem, type: :model do
|
|
52
52
|
|
53
53
|
it_behaves_like 'belongs_to', model_attributes, :shipment, Unidom::Shipment::Shipment, shipment_attributes
|
54
54
|
|
55
|
+
shipment_package_item_1_attributes = {
|
56
|
+
package_id: SecureRandom.uuid,
|
57
|
+
quantity: 10.00
|
58
|
+
}
|
59
|
+
|
60
|
+
shipment_package_item_2_attributes = {
|
61
|
+
package_id: SecureRandom.uuid,
|
62
|
+
quantity: 20.00
|
63
|
+
}
|
64
|
+
|
65
|
+
it_behaves_like 'has_many', model_attributes, :package_items, Unidom::Shipment::ShipmentPackageItem, [ shipment_package_item_1_attributes, shipment_package_item_2_attributes ]
|
66
|
+
|
55
67
|
end
|
56
68
|
|
57
69
|
end
|
@@ -26,6 +26,30 @@ describe Unidom::Shipment::ShipmentPackage, type: :model do
|
|
26
26
|
|
27
27
|
it_behaves_like 'has_many', model_attributes, :items, Unidom::Shipment::ShipmentPackageItem, [ shipment_package_item_1_attributes, shipment_package_item_2_attributes ]
|
28
28
|
|
29
|
+
shipment_receipt_1_attributes = {
|
30
|
+
shipped_id: SecureRandom.uuid,
|
31
|
+
shipped_type: 'Unidom::Shipment::Shipped::Mock',
|
32
|
+
store_item_id: SecureRandom.uuid,
|
33
|
+
store_item_type: 'Unidom::Shipment::StoreItem::Mock',
|
34
|
+
accepted_quantity: 9,
|
35
|
+
rejected_quantity: 1,
|
36
|
+
received_at: Time.now,
|
37
|
+
rejection_reason: 'Broken'
|
38
|
+
}
|
39
|
+
|
40
|
+
shipment_receipt_2_attributes = {
|
41
|
+
shipped_id: SecureRandom.uuid,
|
42
|
+
shipped_type: 'Unidom::Shipment::Shipped::Mock',
|
43
|
+
store_item_id: SecureRandom.uuid,
|
44
|
+
store_item_type: 'Unidom::Shipment::StoreItem::Mock',
|
45
|
+
accepted_quantity: 10,
|
46
|
+
rejected_quantity: 0,
|
47
|
+
received_at: Time.now,
|
48
|
+
rejection_reason: nil
|
49
|
+
}
|
50
|
+
|
51
|
+
it_behaves_like 'has_many', model_attributes, :receipts, Unidom::Shipment::ShipmentReceipt, [ shipment_receipt_1_attributes, shipment_receipt_2_attributes ]
|
52
|
+
|
29
53
|
end
|
30
54
|
|
31
55
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: unidom-shipment
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Topbit Du
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-03-
|
11
|
+
date: 2017-03-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: unidom-common
|