apress-yandex_market 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (36) hide show
  1. checksums.yaml +7 -0
  2. data/.drone.yml +30 -0
  3. data/.gitignore +14 -0
  4. data/.rspec +3 -0
  5. data/CHANGELOG.md +9 -0
  6. data/Gemfile +3 -0
  7. data/README.md +3 -0
  8. data/Rakefile +7 -0
  9. data/apress-yandexmarket.gemspec +36 -0
  10. data/dip.yml +41 -0
  11. data/docker-compose.development.yml +13 -0
  12. data/docker-compose.drone.yml +7 -0
  13. data/docker-compose.yml +9 -0
  14. data/lib/apress/yandex_market/api/client.rb +79 -0
  15. data/lib/apress/yandex_market/api/error.rb +19 -0
  16. data/lib/apress/yandex_market/api/page_error.rb +9 -0
  17. data/lib/apress/yandex_market/api.rb +9 -0
  18. data/lib/apress/yandex_market/presenters/base.rb +49 -0
  19. data/lib/apress/yandex_market/presenters/model.rb +19 -0
  20. data/lib/apress/yandex_market/presenters.rb +8 -0
  21. data/lib/apress/yandex_market/readers/base.rb +54 -0
  22. data/lib/apress/yandex_market/readers/category.rb +117 -0
  23. data/lib/apress/yandex_market/readers/model_by_category.rb +145 -0
  24. data/lib/apress/yandex_market/readers.rb +8 -0
  25. data/lib/apress/yandex_market/version.rb +5 -0
  26. data/lib/apress/yandex_market.rb +9 -0
  27. data/spec/apress/yandex_market/api/client_spec.rb +46 -0
  28. data/spec/apress/yandex_market/readers/category_spec.rb +46 -0
  29. data/spec/apress/yandex_market/readers/model_by_category_spec.rb +29 -0
  30. data/spec/fixtures/get_category_with_invalid_id.yml +81 -0
  31. data/spec/fixtures/get_root_categories.yml +82 -0
  32. data/spec/fixtures/read_models_from_category.yml +29960 -0
  33. data/spec/fixtures/read_two_categories.yml +3600 -0
  34. data/spec/fixtures/read_two_categories_with_page_error.yml +1983 -0
  35. data/spec/spec_helper.rb +27 -0
  36. metadata +240 -0
@@ -0,0 +1,27 @@
1
+ require 'rubygems'
2
+ require 'bundler/setup'
3
+
4
+ require 'simplecov'
5
+
6
+ SimpleCov.start do
7
+ minimum_coverage 95
8
+ end
9
+
10
+ require 'apress/yandex_market'
11
+
12
+ require 'rspec'
13
+ require 'rspec/its'
14
+ require 'rspec/collection_matchers'
15
+
16
+ require 'pry-byebug'
17
+ require 'webmock/rspec'
18
+ require 'vcr'
19
+
20
+ VCR.configure do |config|
21
+ config.cassette_library_dir = 'spec/fixtures'
22
+ config.hook_into :webmock
23
+
24
+ config.before_record do |i|
25
+ i.response.body.force_encoding('UTF-8')
26
+ end
27
+ end
metadata ADDED
@@ -0,0 +1,240 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: apress-yandex_market
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Mikhail Nelaev
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2019-01-10 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: oj
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: facets
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: bundler
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '1.6'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '1.6'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rake
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "<"
60
+ - !ruby/object:Gem::Version
61
+ version: '11.0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "<"
67
+ - !ruby/object:Gem::Version
68
+ version: '11.0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: rspec
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-its
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: rspec-collection_matchers
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: webmock
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - "<"
116
+ - !ruby/object:Gem::Version
117
+ version: '2.3'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - "<"
123
+ - !ruby/object:Gem::Version
124
+ version: '2.3'
125
+ - !ruby/object:Gem::Dependency
126
+ name: vcr
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - ">="
130
+ - !ruby/object:Gem::Version
131
+ version: '0'
132
+ type: :development
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - ">="
137
+ - !ruby/object:Gem::Version
138
+ version: '0'
139
+ - !ruby/object:Gem::Dependency
140
+ name: simplecov
141
+ requirement: !ruby/object:Gem::Requirement
142
+ requirements:
143
+ - - "~>"
144
+ - !ruby/object:Gem::Version
145
+ version: 0.10.0
146
+ type: :development
147
+ prerelease: false
148
+ version_requirements: !ruby/object:Gem::Requirement
149
+ requirements:
150
+ - - "~>"
151
+ - !ruby/object:Gem::Version
152
+ version: 0.10.0
153
+ - !ruby/object:Gem::Dependency
154
+ name: pry-byebug
155
+ requirement: !ruby/object:Gem::Requirement
156
+ requirements:
157
+ - - ">="
158
+ - !ruby/object:Gem::Version
159
+ version: '0'
160
+ type: :development
161
+ prerelease: false
162
+ version_requirements: !ruby/object:Gem::Requirement
163
+ requirements:
164
+ - - ">="
165
+ - !ruby/object:Gem::Version
166
+ version: '0'
167
+ description:
168
+ email:
169
+ - spyderdfx@gmail.com
170
+ executables: []
171
+ extensions: []
172
+ extra_rdoc_files: []
173
+ files:
174
+ - ".drone.yml"
175
+ - ".gitignore"
176
+ - ".rspec"
177
+ - CHANGELOG.md
178
+ - Gemfile
179
+ - README.md
180
+ - Rakefile
181
+ - apress-yandexmarket.gemspec
182
+ - dip.yml
183
+ - docker-compose.development.yml
184
+ - docker-compose.drone.yml
185
+ - docker-compose.yml
186
+ - lib/apress/yandex_market.rb
187
+ - lib/apress/yandex_market/api.rb
188
+ - lib/apress/yandex_market/api/client.rb
189
+ - lib/apress/yandex_market/api/error.rb
190
+ - lib/apress/yandex_market/api/page_error.rb
191
+ - lib/apress/yandex_market/presenters.rb
192
+ - lib/apress/yandex_market/presenters/base.rb
193
+ - lib/apress/yandex_market/presenters/model.rb
194
+ - lib/apress/yandex_market/readers.rb
195
+ - lib/apress/yandex_market/readers/base.rb
196
+ - lib/apress/yandex_market/readers/category.rb
197
+ - lib/apress/yandex_market/readers/model_by_category.rb
198
+ - lib/apress/yandex_market/version.rb
199
+ - spec/apress/yandex_market/api/client_spec.rb
200
+ - spec/apress/yandex_market/readers/category_spec.rb
201
+ - spec/apress/yandex_market/readers/model_by_category_spec.rb
202
+ - spec/fixtures/get_category_with_invalid_id.yml
203
+ - spec/fixtures/get_root_categories.yml
204
+ - spec/fixtures/read_models_from_category.yml
205
+ - spec/fixtures/read_two_categories.yml
206
+ - spec/fixtures/read_two_categories_with_page_error.yml
207
+ - spec/spec_helper.rb
208
+ homepage: https://github.com/abak-press/apress-yandex_market
209
+ licenses: []
210
+ metadata: {}
211
+ post_install_message:
212
+ rdoc_options: []
213
+ require_paths:
214
+ - lib
215
+ required_ruby_version: !ruby/object:Gem::Requirement
216
+ requirements:
217
+ - - ">="
218
+ - !ruby/object:Gem::Version
219
+ version: '0'
220
+ required_rubygems_version: !ruby/object:Gem::Requirement
221
+ requirements:
222
+ - - ">="
223
+ - !ruby/object:Gem::Version
224
+ version: '0'
225
+ requirements: []
226
+ rubyforge_project:
227
+ rubygems_version: 2.6.1
228
+ signing_key:
229
+ specification_version: 4
230
+ summary: Tools for synchronization with Yandex.Market
231
+ test_files:
232
+ - spec/apress/yandex_market/api/client_spec.rb
233
+ - spec/apress/yandex_market/readers/category_spec.rb
234
+ - spec/apress/yandex_market/readers/model_by_category_spec.rb
235
+ - spec/fixtures/get_category_with_invalid_id.yml
236
+ - spec/fixtures/get_root_categories.yml
237
+ - spec/fixtures/read_models_from_category.yml
238
+ - spec/fixtures/read_two_categories.yml
239
+ - spec/fixtures/read_two_categories_with_page_error.yml
240
+ - spec/spec_helper.rb