dear-inventory-ruby 0.1.8 → 0.1.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -0
- data/Gemfile +1 -1
- data/README.md +8 -4
- data/dear-inventory-ruby.gemspec +1 -1
- data/docs/Account.md +15 -15
- data/docs/Accounts.md +3 -3
- data/docs/Address.md +9 -9
- data/docs/Contact.md +9 -9
- data/docs/Customer.md +31 -31
- data/docs/Customers.md +3 -3
- data/docs/DimensionsUnit.md +16 -0
- data/docs/Error.md +2 -2
- data/docs/InventoryApi.md +54 -0
- data/docs/Me.md +29 -0
- data/docs/PaymentTerm.md +6 -6
- data/docs/PaymentTerms.md +3 -3
- data/docs/Success.md +1 -1
- data/docs/Tax.md +9 -9
- data/docs/TaxComponent.md +4 -4
- data/docs/Taxes.md +3 -3
- data/docs/WeightUnit.md +16 -0
- data/lib/dear-inventory-ruby.rb +4 -1
- data/lib/dear-inventory-ruby/api/inventory_api.rb +55 -1
- data/lib/dear-inventory-ruby/api_client.rb +1 -1
- data/lib/dear-inventory-ruby/api_error.rb +1 -1
- data/lib/dear-inventory-ruby/configuration.rb +1 -1
- data/lib/dear-inventory-ruby/models/account.rb +1 -1
- data/lib/dear-inventory-ruby/models/accounts.rb +1 -1
- data/lib/dear-inventory-ruby/models/address.rb +1 -1
- data/lib/dear-inventory-ruby/models/contact.rb +1 -1
- data/lib/dear-inventory-ruby/models/currency_code.rb +1 -1
- data/lib/dear-inventory-ruby/models/customer.rb +1 -1
- data/lib/dear-inventory-ruby/models/customers.rb +1 -1
- data/lib/dear-inventory-ruby/models/dimensions_unit.rb +42 -0
- data/lib/dear-inventory-ruby/models/error.rb +1 -1
- data/lib/dear-inventory-ruby/models/me.rb +264 -0
- data/lib/dear-inventory-ruby/models/payment_term.rb +1 -1
- data/lib/dear-inventory-ruby/models/payment_terms.rb +1 -1
- data/lib/dear-inventory-ruby/models/success.rb +1 -1
- data/lib/dear-inventory-ruby/models/tax.rb +1 -1
- data/lib/dear-inventory-ruby/models/tax_component.rb +1 -1
- data/lib/dear-inventory-ruby/models/taxes.rb +1 -1
- data/lib/dear-inventory-ruby/models/weight_unit.rb +39 -0
- data/lib/dear-inventory-ruby/version.rb +2 -2
- data/spec/api/inventory_api_spec.rb +11 -1
- data/spec/api_client_spec.rb +2 -2
- data/spec/configuration_spec.rb +1 -1
- data/spec/models/account_spec.rb +1 -1
- data/spec/models/accounts_spec.rb +1 -1
- data/spec/models/address_spec.rb +1 -1
- data/spec/models/contact_spec.rb +1 -1
- data/spec/models/currency_code_spec.rb +1 -1
- data/spec/models/customer_spec.rb +1 -1
- data/spec/models/customers_spec.rb +1 -1
- data/spec/models/dimensions_unit_spec.rb +35 -0
- data/spec/models/error_spec.rb +1 -1
- data/spec/models/me_spec.rb +77 -0
- data/spec/models/payment_term_spec.rb +1 -1
- data/spec/models/payment_terms_spec.rb +1 -1
- data/spec/models/success_spec.rb +1 -1
- data/spec/models/tax_component_spec.rb +1 -1
- data/spec/models/tax_spec.rb +1 -1
- data/spec/models/taxes_spec.rb +1 -1
- data/spec/models/weight_unit_spec.rb +35 -0
- data/spec/spec_helper.rb +1 -1
- metadata +14 -2
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#DEAR Inventory API
|
3
|
+
|
4
|
+
#This specifing endpoints for DEAR Inventory API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 2.0.0
|
7
|
+
Contact: nnhansg@gmail.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module DearInventoryRuby
|
16
|
+
class WeightUnit
|
17
|
+
OZ = "oz".freeze
|
18
|
+
MG = "mg".freeze
|
19
|
+
KG = "kg".freeze
|
20
|
+
LB = "lb".freeze
|
21
|
+
G = "g".freeze
|
22
|
+
|
23
|
+
# Builds the enum from string
|
24
|
+
# @param [String] The enum value in the form of the string
|
25
|
+
# @return [String] The enum value
|
26
|
+
def self.build_from_hash(value)
|
27
|
+
new.build_from_hash(value)
|
28
|
+
end
|
29
|
+
|
30
|
+
# Builds the enum from string
|
31
|
+
# @param [String] The enum value in the form of the string
|
32
|
+
# @return [String] The enum value
|
33
|
+
def build_from_hash(value)
|
34
|
+
constantValues = WeightUnit.constants.select { |c| WeightUnit::const_get(c) == value }
|
35
|
+
raise "Invalid ENUM value #{value} for class #WeightUnit" if constantValues.empty?
|
36
|
+
value
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -6,10 +6,10 @@
|
|
6
6
|
The version of the OpenAPI document: 2.0.0
|
7
7
|
Contact: nnhansg@gmail.com
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 4.
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
module DearInventoryRuby
|
14
|
-
VERSION = '0.1.
|
14
|
+
VERSION = '0.1.9'
|
15
15
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 2.0.0
|
7
7
|
Contact: nnhansg@gmail.com
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 4.
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -134,6 +134,16 @@ describe 'InventoryApi' do
|
|
134
134
|
end
|
135
135
|
end
|
136
136
|
|
137
|
+
# unit tests for get_me
|
138
|
+
# Allows you to retrieve your information
|
139
|
+
# @param [Hash] opts the optional parameters
|
140
|
+
# @return [Me]
|
141
|
+
describe 'get_me test' do
|
142
|
+
it 'should work' do
|
143
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
144
|
+
end
|
145
|
+
end
|
146
|
+
|
137
147
|
# unit tests for get_payment_terms
|
138
148
|
# Allows you to retrieve the payment terms
|
139
149
|
# @param [Hash] opts the optional parameters
|
data/spec/api_client_spec.rb
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
The version of the OpenAPI document: 2.0.0
|
7
7
|
Contact: nnhansg@gmail.com
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 4.
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -118,7 +118,7 @@ describe DearInventoryRuby::ApiClient do
|
|
118
118
|
end
|
119
119
|
|
120
120
|
it 'fails for invalid collection format' do
|
121
|
-
expect{api_client.build_collection_param(param, :INVALID)}.to raise_error(RuntimeError, 'unknown collection format: :INVALID')
|
121
|
+
expect { api_client.build_collection_param(param, :INVALID) }.to raise_error(RuntimeError, 'unknown collection format: :INVALID')
|
122
122
|
end
|
123
123
|
end
|
124
124
|
|
data/spec/configuration_spec.rb
CHANGED
data/spec/models/account_spec.rb
CHANGED
data/spec/models/address_spec.rb
CHANGED
data/spec/models/contact_spec.rb
CHANGED
@@ -0,0 +1,35 @@
|
|
1
|
+
=begin
|
2
|
+
#DEAR Inventory API
|
3
|
+
|
4
|
+
#This specifing endpoints for DEAR Inventory API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 2.0.0
|
7
|
+
Contact: nnhansg@gmail.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
require 'date'
|
16
|
+
|
17
|
+
# Unit tests for DearInventoryRuby::DimensionsUnit
|
18
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
19
|
+
# Please update as you see appropriate
|
20
|
+
describe 'DimensionsUnit' do
|
21
|
+
before do
|
22
|
+
# run before each test
|
23
|
+
@instance = DearInventoryRuby::DimensionsUnit.new
|
24
|
+
end
|
25
|
+
|
26
|
+
after do
|
27
|
+
# run after each test
|
28
|
+
end
|
29
|
+
|
30
|
+
describe 'test an instance of DimensionsUnit' do
|
31
|
+
it 'should create an instance of DimensionsUnit' do
|
32
|
+
expect(@instance).to be_instance_of(DearInventoryRuby::DimensionsUnit)
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
data/spec/models/error_spec.rb
CHANGED
@@ -0,0 +1,77 @@
|
|
1
|
+
=begin
|
2
|
+
#DEAR Inventory API
|
3
|
+
|
4
|
+
#This specifing endpoints for DEAR Inventory API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 2.0.0
|
7
|
+
Contact: nnhansg@gmail.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
require 'date'
|
16
|
+
|
17
|
+
# Unit tests for DearInventoryRuby::Me
|
18
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
19
|
+
# Please update as you see appropriate
|
20
|
+
describe 'Me' do
|
21
|
+
before do
|
22
|
+
# run before each test
|
23
|
+
@instance = DearInventoryRuby::Me.new
|
24
|
+
end
|
25
|
+
|
26
|
+
after do
|
27
|
+
# run after each test
|
28
|
+
end
|
29
|
+
|
30
|
+
describe 'test an instance of Me' do
|
31
|
+
it 'should create an instance of Me' do
|
32
|
+
expect(@instance).to be_instance_of(DearInventoryRuby::Me)
|
33
|
+
end
|
34
|
+
end
|
35
|
+
describe 'test attribute "company"' do
|
36
|
+
it 'should work' do
|
37
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
38
|
+
end
|
39
|
+
end
|
40
|
+
|
41
|
+
describe 'test attribute "currency"' do
|
42
|
+
it 'should work' do
|
43
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
describe 'test attribute "time_zone"' do
|
48
|
+
it 'should work' do
|
49
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
50
|
+
end
|
51
|
+
end
|
52
|
+
|
53
|
+
describe 'test attribute "default_weight_units"' do
|
54
|
+
it 'should work' do
|
55
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
describe 'test attribute "default_dimensions_units"' do
|
60
|
+
it 'should work' do
|
61
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
62
|
+
end
|
63
|
+
end
|
64
|
+
|
65
|
+
describe 'test attribute "lock_date"' do
|
66
|
+
it 'should work' do
|
67
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
68
|
+
end
|
69
|
+
end
|
70
|
+
|
71
|
+
describe 'test attribute "opening_balance_date"' do
|
72
|
+
it 'should work' do
|
73
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
74
|
+
end
|
75
|
+
end
|
76
|
+
|
77
|
+
end
|
data/spec/models/success_spec.rb
CHANGED
data/spec/models/tax_spec.rb
CHANGED
data/spec/models/taxes_spec.rb
CHANGED
@@ -0,0 +1,35 @@
|
|
1
|
+
=begin
|
2
|
+
#DEAR Inventory API
|
3
|
+
|
4
|
+
#This specifing endpoints for DEAR Inventory API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 2.0.0
|
7
|
+
Contact: nnhansg@gmail.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
require 'date'
|
16
|
+
|
17
|
+
# Unit tests for DearInventoryRuby::WeightUnit
|
18
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
19
|
+
# Please update as you see appropriate
|
20
|
+
describe 'WeightUnit' do
|
21
|
+
before do
|
22
|
+
# run before each test
|
23
|
+
@instance = DearInventoryRuby::WeightUnit.new
|
24
|
+
end
|
25
|
+
|
26
|
+
after do
|
27
|
+
# run after each test
|
28
|
+
end
|
29
|
+
|
30
|
+
describe 'test an instance of WeightUnit' do
|
31
|
+
it 'should create an instance of WeightUnit' do
|
32
|
+
expect(@instance).to be_instance_of(DearInventoryRuby::WeightUnit)
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|