companies_house_input_gateway 0.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. checksums.yaml +7 -0
  2. data/lib/base.rb +9 -0
  3. data/lib/companies_house_input_gateway/client.rb +46 -0
  4. data/lib/companies_house_input_gateway/config.rb +35 -0
  5. data/lib/companies_house_input_gateway/constants.rb +21 -0
  6. data/lib/companies_house_input_gateway/errors/api_error.rb +18 -0
  7. data/lib/companies_house_input_gateway/errors/companies_house_gateway_error.rb +20 -0
  8. data/lib/companies_house_input_gateway/errors/invalid_request_error.rb +12 -0
  9. data/lib/companies_house_input_gateway/errors/invalid_response_error.rb +6 -0
  10. data/lib/companies_house_input_gateway/form_validator.rb +29 -0
  11. data/lib/companies_house_input_gateway/forms/form_abstract_builder.rb +61 -0
  12. data/lib/companies_house_input_gateway/forms/form_company_data_request.rb +20 -0
  13. data/lib/companies_house_input_gateway/forms/form_confirmation_statement.rb +21 -0
  14. data/lib/companies_house_input_gateway/forms/form_get_submission_status.rb +21 -0
  15. data/lib/companies_house_input_gateway/forms/form_returnof_allotment_shares.rb +21 -0
  16. data/lib/companies_house_input_gateway/forms/form_submission.rb +39 -0
  17. data/lib/companies_house_input_gateway/middleware/check_response.rb +30 -0
  18. data/lib/companies_house_input_gateway/request.rb +57 -0
  19. data/lib/companies_house_input_gateway/requests/abstract_performer.rb +52 -0
  20. data/lib/companies_house_input_gateway/requests/company_data_request.rb +9 -0
  21. data/lib/companies_house_input_gateway/requests/confirmation_statement.rb +11 -0
  22. data/lib/companies_house_input_gateway/requests/get_submission_status.rb +9 -0
  23. data/lib/companies_house_input_gateway/requests/returnof_allotment_shares.rb +11 -0
  24. data/lib/companies_house_input_gateway/util.rb +28 -0
  25. data/lib/companies_house_input_gateway/validations/company_data_request.rb +20 -0
  26. data/lib/companies_house_input_gateway/validations/confirmation_statement.rb +96 -0
  27. data/lib/companies_house_input_gateway/validations/form_submission.rb +23 -0
  28. data/lib/companies_house_input_gateway/validations/get_submission_status.rb +24 -0
  29. data/lib/companies_house_input_gateway/validations/returnof_allotment_shares.rb +41 -0
  30. data/lib/companies_house_input_gateway/version.rb +5 -0
  31. data/lib/companies_house_input_gateway/xml_forms_binder.rb +81 -0
  32. data/lib/companies_house_input_gateway.rb +76 -0
  33. data/spec/client_spec.rb +59 -0
  34. data/spec/companies_house_input_gateway_spec.rb +47 -0
  35. data/spec/data_samples.rb +147 -0
  36. data/spec/fixtures/bad_response.xml +35 -0
  37. data/spec/fixtures/response_company_data_request.xml +330 -0
  38. data/spec/fixtures/response_confirmation_statement.xml +28 -0
  39. data/spec/fixtures/response_get_submission_status.xml +40 -0
  40. data/spec/fixtures/response_returnof_allotment_shares.xml +28 -0
  41. data/spec/form_validator_spec.rb +61 -0
  42. data/spec/request_spec.rb +132 -0
  43. data/spec/spec_helper.rb +32 -0
  44. metadata +206 -0
metadata ADDED
@@ -0,0 +1,206 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: companies_house_input_gateway
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.6
5
+ platform: ruby
6
+ authors:
7
+ - Illia Buch
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2022-03-28 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: dry-validation
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: 0.11.1
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: 0.11.1
27
+ - !ruby/object:Gem::Dependency
28
+ name: faraday_middleware
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: 1.0.0
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: 1.0.0
41
+ - !ruby/object:Gem::Dependency
42
+ name: multi_xml
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: 0.5.1
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: 0.5.1
55
+ - !ruby/object:Gem::Dependency
56
+ name: nokogiri
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '1.4'
62
+ type: :runtime
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '1.4'
69
+ - !ruby/object:Gem::Dependency
70
+ name: pry-byebug
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '3.5'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '3.5'
83
+ - !ruby/object:Gem::Dependency
84
+ name: rspec
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - "~>"
88
+ - !ruby/object:Gem::Version
89
+ version: '3.0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - "~>"
95
+ - !ruby/object:Gem::Version
96
+ version: '3.0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: rubocop
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - "~>"
102
+ - !ruby/object:Gem::Version
103
+ version: 0.93.1
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - "~>"
109
+ - !ruby/object:Gem::Version
110
+ version: 0.93.1
111
+ - !ruby/object:Gem::Dependency
112
+ name: webmock
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - "~>"
116
+ - !ruby/object:Gem::Version
117
+ version: 3.9.3
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - "~>"
123
+ - !ruby/object:Gem::Version
124
+ version: 3.9.3
125
+ description: Ruby wrapper for the Companies House Input XML Gateway
126
+ email: illiya.buchinskiy@gmail.com
127
+ executables: []
128
+ extensions: []
129
+ extra_rdoc_files: []
130
+ files:
131
+ - lib/base.rb
132
+ - lib/companies_house_input_gateway.rb
133
+ - lib/companies_house_input_gateway/client.rb
134
+ - lib/companies_house_input_gateway/config.rb
135
+ - lib/companies_house_input_gateway/constants.rb
136
+ - lib/companies_house_input_gateway/errors/api_error.rb
137
+ - lib/companies_house_input_gateway/errors/companies_house_gateway_error.rb
138
+ - lib/companies_house_input_gateway/errors/invalid_request_error.rb
139
+ - lib/companies_house_input_gateway/errors/invalid_response_error.rb
140
+ - lib/companies_house_input_gateway/form_validator.rb
141
+ - lib/companies_house_input_gateway/forms/form_abstract_builder.rb
142
+ - lib/companies_house_input_gateway/forms/form_company_data_request.rb
143
+ - lib/companies_house_input_gateway/forms/form_confirmation_statement.rb
144
+ - lib/companies_house_input_gateway/forms/form_get_submission_status.rb
145
+ - lib/companies_house_input_gateway/forms/form_returnof_allotment_shares.rb
146
+ - lib/companies_house_input_gateway/forms/form_submission.rb
147
+ - lib/companies_house_input_gateway/middleware/check_response.rb
148
+ - lib/companies_house_input_gateway/request.rb
149
+ - lib/companies_house_input_gateway/requests/abstract_performer.rb
150
+ - lib/companies_house_input_gateway/requests/company_data_request.rb
151
+ - lib/companies_house_input_gateway/requests/confirmation_statement.rb
152
+ - lib/companies_house_input_gateway/requests/get_submission_status.rb
153
+ - lib/companies_house_input_gateway/requests/returnof_allotment_shares.rb
154
+ - lib/companies_house_input_gateway/util.rb
155
+ - lib/companies_house_input_gateway/validations/company_data_request.rb
156
+ - lib/companies_house_input_gateway/validations/confirmation_statement.rb
157
+ - lib/companies_house_input_gateway/validations/form_submission.rb
158
+ - lib/companies_house_input_gateway/validations/get_submission_status.rb
159
+ - lib/companies_house_input_gateway/validations/returnof_allotment_shares.rb
160
+ - lib/companies_house_input_gateway/version.rb
161
+ - lib/companies_house_input_gateway/xml_forms_binder.rb
162
+ - spec/client_spec.rb
163
+ - spec/companies_house_input_gateway_spec.rb
164
+ - spec/data_samples.rb
165
+ - spec/fixtures/bad_response.xml
166
+ - spec/fixtures/response_company_data_request.xml
167
+ - spec/fixtures/response_confirmation_statement.xml
168
+ - spec/fixtures/response_get_submission_status.xml
169
+ - spec/fixtures/response_returnof_allotment_shares.xml
170
+ - spec/form_validator_spec.rb
171
+ - spec/request_spec.rb
172
+ - spec/spec_helper.rb
173
+ homepage: https://github.com/Globacap/companies_house_input_gateway
174
+ licenses: []
175
+ metadata: {}
176
+ post_install_message:
177
+ rdoc_options: []
178
+ require_paths:
179
+ - lib
180
+ required_ruby_version: !ruby/object:Gem::Requirement
181
+ requirements:
182
+ - - "<="
183
+ - !ruby/object:Gem::Version
184
+ version: 2.7.2
185
+ required_rubygems_version: !ruby/object:Gem::Requirement
186
+ requirements:
187
+ - - ">="
188
+ - !ruby/object:Gem::Version
189
+ version: '0'
190
+ requirements: []
191
+ rubygems_version: 3.0.3
192
+ signing_key:
193
+ specification_version: 4
194
+ summary: Ruby wrapper for the Companies House Input XML Gateway API
195
+ test_files:
196
+ - spec/client_spec.rb
197
+ - spec/companies_house_input_gateway_spec.rb
198
+ - spec/data_samples.rb
199
+ - spec/fixtures/bad_response.xml
200
+ - spec/fixtures/response_company_data_request.xml
201
+ - spec/fixtures/response_confirmation_statement.xml
202
+ - spec/fixtures/response_get_submission_status.xml
203
+ - spec/fixtures/response_returnof_allotment_shares.xml
204
+ - spec/form_validator_spec.rb
205
+ - spec/request_spec.rb
206
+ - spec/spec_helper.rb