tax_cloud 0.3.0 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (82) hide show
  1. checksums.yaml +5 -5
  2. data/.rubocop.yml +8 -25
  3. data/.rubocop_todo.yml +47 -0
  4. data/.travis.yml +5 -5
  5. data/CHANGELOG.rdoc +11 -0
  6. data/CONTRIBUTORS.txt +3 -0
  7. data/Gemfile +16 -5
  8. data/LICENSE.rdoc +1 -1
  9. data/README.rdoc +12 -8
  10. data/Rakefile +7 -11
  11. data/lib/config/locales/en.yml +2 -2
  12. data/lib/hash.rb +3 -4
  13. data/lib/tasks/tax_cloud.rake +4 -4
  14. data/lib/tasks/tax_code_groups.rake +11 -11
  15. data/lib/tasks/tax_codes.rake +12 -12
  16. data/lib/tax_cloud.rb +8 -3
  17. data/lib/tax_cloud/address.rb +10 -5
  18. data/lib/tax_cloud/cart_item.rb +2 -0
  19. data/lib/tax_cloud/client.rb +13 -3
  20. data/lib/tax_cloud/configuration.rb +13 -2
  21. data/lib/tax_cloud/errors.rb +2 -0
  22. data/lib/tax_cloud/errors/api_error.rb +3 -3
  23. data/lib/tax_cloud/errors/missing_config_error.rb +2 -1
  24. data/lib/tax_cloud/errors/missing_config_option_error.rb +2 -1
  25. data/lib/tax_cloud/errors/soap_error.rb +6 -6
  26. data/lib/tax_cloud/errors/tax_cloud_error.rb +4 -3
  27. data/lib/tax_cloud/errors/unexpected_soap_response_error.rb +3 -3
  28. data/lib/tax_cloud/record.rb +2 -0
  29. data/lib/tax_cloud/responses.rb +2 -0
  30. data/lib/tax_cloud/responses/authorized.rb +3 -1
  31. data/lib/tax_cloud/responses/authorized_with_capture.rb +3 -1
  32. data/lib/tax_cloud/responses/base.rb +5 -4
  33. data/lib/tax_cloud/responses/captured.rb +3 -1
  34. data/lib/tax_cloud/responses/cart_item.rb +6 -2
  35. data/lib/tax_cloud/responses/generic.rb +2 -0
  36. data/lib/tax_cloud/responses/lookup.rb +10 -8
  37. data/lib/tax_cloud/responses/ping.rb +3 -1
  38. data/lib/tax_cloud/responses/returned.rb +3 -1
  39. data/lib/tax_cloud/responses/tax_code_groups.rb +3 -1
  40. data/lib/tax_cloud/responses/tax_codes.rb +3 -1
  41. data/lib/tax_cloud/responses/tax_codes_by_group.rb +3 -1
  42. data/lib/tax_cloud/responses/verify_address.rb +3 -1
  43. data/lib/tax_cloud/tax_code.rb +2 -0
  44. data/lib/tax_cloud/tax_code_constants.rb +262 -260
  45. data/lib/tax_cloud/tax_code_group.rb +3 -1
  46. data/lib/tax_cloud/tax_code_group_constants.rb +2 -0
  47. data/lib/tax_cloud/tax_code_groups.rb +3 -1
  48. data/lib/tax_cloud/tax_codes.rb +3 -1
  49. data/lib/tax_cloud/transaction.rb +2 -0
  50. data/lib/tax_cloud/version.rb +3 -1
  51. data/tax_cloud.gemspec +16 -18
  52. data/test/cassettes/authorized.yml +6 -6
  53. data/test/cassettes/authorized_with_capture.yml +6 -6
  54. data/test/cassettes/authorized_with_localized_time.yml +6 -6
  55. data/test/cassettes/captured.yml +7 -7
  56. data/test/cassettes/get_tic_groups.yml +5 -5
  57. data/test/cassettes/get_tics.yml +5 -5
  58. data/test/cassettes/get_tics_by_group.yml +5 -5
  59. data/test/cassettes/invalid_soap_call.yml +5 -5
  60. data/test/cassettes/lookup.yml +5 -5
  61. data/test/cassettes/lookup_ny.yml +5 -5
  62. data/test/cassettes/ping.yml +5 -5
  63. data/test/cassettes/ping_with_invalid_credentials.yml +5 -5
  64. data/test/cassettes/ping_with_invalid_response.yml +5 -5
  65. data/test/cassettes/returned.yml +7 -7
  66. data/test/cassettes/verify_bad_address.yml +5 -5
  67. data/test/cassettes/verify_good_address.yml +5 -5
  68. data/test/helper.rb +3 -1
  69. data/test/test_address.rb +3 -1
  70. data/test/test_cart_item.rb +3 -1
  71. data/test/test_client.rb +4 -2
  72. data/test/test_configuration_optional_keys.rb +44 -0
  73. data/test/{test_configuration.rb → test_configuration_required_keys.rb} +6 -4
  74. data/test/test_lookup_response.rb +22 -0
  75. data/test/test_setup.rb +3 -1
  76. data/test/test_soap.rb +3 -1
  77. data/test/test_tax_code_groups.rb +4 -2
  78. data/test/test_tax_codes.rb +3 -1
  79. data/test/test_transaction.rb +3 -1
  80. data/test/test_transaction_ny.rb +3 -1
  81. data/test/vcr_setup.rb +2 -0
  82. metadata +28 -96
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'vcr'
2
4
 
3
5
  VCR.configure do |c|
metadata CHANGED
@@ -1,127 +1,57 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tax_cloud
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Drew Tempelmeyer
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-01-09 00:00:00.000000000 Z
11
+ date: 2020-12-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: savon
14
+ name: activesupport
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '2.0'
19
+ version: '3.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: '2.0'
26
+ version: '3.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: i18n
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '0'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
- name: activesupport
42
+ name: savon
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '>='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
- version: '3.0'
47
+ version: '2.0'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '>='
53
- - !ruby/object:Gem::Version
54
- version: '3.0'
55
- - !ruby/object:Gem::Dependency
56
- name: rake
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - '>='
60
- - !ruby/object:Gem::Version
61
- version: '0.9'
62
- type: :development
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - '>='
67
- - !ruby/object:Gem::Version
68
- version: '0.9'
69
- - !ruby/object:Gem::Dependency
70
- name: rdoc
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - '>='
74
- - !ruby/object:Gem::Version
75
- version: 2.5.0
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - '>='
81
- - !ruby/object:Gem::Version
82
- version: 2.5.0
83
- - !ruby/object:Gem::Dependency
84
- name: vcr
85
- requirement: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - ~>
88
- - !ruby/object:Gem::Version
89
- version: '2.3'
90
- type: :development
91
- prerelease: false
92
- version_requirements: !ruby/object:Gem::Requirement
93
- requirements:
94
- - - ~>
95
- - !ruby/object:Gem::Version
96
- version: '2.3'
97
- - !ruby/object:Gem::Dependency
98
- name: webmock
99
- requirement: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - ~>
102
- - !ruby/object:Gem::Version
103
- version: 1.8.0
104
- type: :development
105
- prerelease: false
106
- version_requirements: !ruby/object:Gem::Requirement
107
- requirements:
108
- - - ~>
52
+ - - ">="
109
53
  - !ruby/object:Gem::Version
110
- version: 1.8.0
111
- - !ruby/object:Gem::Dependency
112
- name: rubocop
113
- requirement: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - ~>
116
- - !ruby/object:Gem::Version
117
- version: 0.16.0
118
- type: :development
119
- prerelease: false
120
- version_requirements: !ruby/object:Gem::Requirement
121
- requirements:
122
- - - ~>
123
- - !ruby/object:Gem::Version
124
- version: 0.16.0
54
+ version: '2.0'
125
55
  description: Calculate sales tax using the TaxCloud.net API
126
56
  email:
127
57
  - drewtemp@gmail.com
@@ -129,9 +59,10 @@ executables: []
129
59
  extensions: []
130
60
  extra_rdoc_files: []
131
61
  files:
132
- - .gitignore
133
- - .rubocop.yml
134
- - .travis.yml
62
+ - ".gitignore"
63
+ - ".rubocop.yml"
64
+ - ".rubocop_todo.yml"
65
+ - ".travis.yml"
135
66
  - CHANGELOG.rdoc
136
67
  - CONTRIBUTORS.txt
137
68
  - Gemfile
@@ -199,7 +130,9 @@ files:
199
130
  - test/test_address.rb
200
131
  - test/test_cart_item.rb
201
132
  - test/test_client.rb
202
- - test/test_configuration.rb
133
+ - test/test_configuration_optional_keys.rb
134
+ - test/test_configuration_required_keys.rb
135
+ - test/test_lookup_response.rb
203
136
  - test/test_setup.rb
204
137
  - test/test_soap.rb
205
138
  - test/test_tax_code_groups.rb
@@ -211,24 +144,23 @@ homepage: https://github.com/drewtempelmeyer/tax_cloud
211
144
  licenses:
212
145
  - MIT
213
146
  metadata: {}
214
- post_install_message:
147
+ post_install_message:
215
148
  rdoc_options: []
216
149
  require_paths:
217
150
  - lib
218
151
  required_ruby_version: !ruby/object:Gem::Requirement
219
152
  requirements:
220
- - - '>='
153
+ - - ">="
221
154
  - !ruby/object:Gem::Version
222
- version: '0'
155
+ version: 2.6.0
223
156
  required_rubygems_version: !ruby/object:Gem::Requirement
224
157
  requirements:
225
- - - '>='
158
+ - - ">="
226
159
  - !ruby/object:Gem::Version
227
160
  version: 1.3.6
228
161
  requirements: []
229
- rubyforge_project:
230
- rubygems_version: 2.1.11
231
- signing_key:
162
+ rubygems_version: 3.1.3
163
+ signing_key:
232
164
  specification_version: 4
233
165
  summary: Calculate sales tax using TaxCloud
234
166
  test_files: []