betfair_api_ng_rails 1.0.0 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (84) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +12 -1
  3. data/Rakefile +8 -8
  4. data/lib/betfair_api_ng_rails/api/connection.rb +3 -0
  5. data/lib/betfair_api_ng_rails/api/connection_ext/error_handling.rb +31 -0
  6. data/lib/betfair_api_ng_rails/api/connection_ext/formatting.rb +0 -1
  7. data/lib/betfair_api_ng_rails/api/connection_ext/parsing.rb +0 -1
  8. data/lib/betfair_api_ng_rails/api/data/base.rb +2 -1
  9. data/lib/betfair_api_ng_rails/api/data/competition.rb +7 -6
  10. data/lib/betfair_api_ng_rails/api/data/competition_result.rb +6 -10
  11. data/lib/betfair_api_ng_rails/api/data/concerns/attributable.rb +51 -0
  12. data/lib/betfair_api_ng_rails/api/data/concerns/hashable.rb +7 -2
  13. data/lib/betfair_api_ng_rails/api/data/concerns/jsonable.rb +46 -0
  14. data/lib/betfair_api_ng_rails/api/data/constants.rb +1 -1
  15. data/lib/betfair_api_ng_rails/api/data/country_code_result.rb +5 -8
  16. data/lib/betfair_api_ng_rails/api/data/event.rb +9 -4
  17. data/lib/betfair_api_ng_rails/api/data/event_result.rb +5 -8
  18. data/lib/betfair_api_ng_rails/api/data/event_type.rb +5 -4
  19. data/lib/betfair_api_ng_rails/api/data/event_type_result.rb +5 -8
  20. data/lib/betfair_api_ng_rails/api/data/ex_best_offers_overrides.rb +24 -0
  21. data/lib/betfair_api_ng_rails/api/data/exchange_prices.rb +16 -0
  22. data/lib/betfair_api_ng_rails/api/data/market_book.rb +31 -0
  23. data/lib/betfair_api_ng_rails/api/data/market_catalogue.rb +23 -0
  24. data/lib/betfair_api_ng_rails/api/data/market_description.rb +29 -0
  25. data/lib/betfair_api_ng_rails/api/data/market_filter.rb +18 -1
  26. data/lib/betfair_api_ng_rails/api/data/market_type_result.rb +5 -8
  27. data/lib/betfair_api_ng_rails/api/data/match.rb +19 -0
  28. data/lib/betfair_api_ng_rails/api/data/order.rb +29 -0
  29. data/lib/betfair_api_ng_rails/api/data/price_projection.rb +23 -0
  30. data/lib/betfair_api_ng_rails/api/data/price_size.rb +15 -0
  31. data/lib/betfair_api_ng_rails/api/data/runner.rb +24 -0
  32. data/lib/betfair_api_ng_rails/api/data/runner_catalog.rb +19 -0
  33. data/lib/betfair_api_ng_rails/api/data/starting_prices.rb +18 -0
  34. data/lib/betfair_api_ng_rails/api/data/time_range.rb +5 -4
  35. data/lib/betfair_api_ng_rails/api/data/time_range_result.rb +5 -8
  36. data/lib/betfair_api_ng_rails/api/data/venue_result.rb +5 -8
  37. data/lib/betfair_api_ng_rails/api/hashalator.rb +2 -1
  38. data/lib/betfair_api_ng_rails/api/parsers/base.rb +0 -2
  39. data/lib/betfair_api_ng_rails/api/parsers/list_market_book.rb +15 -0
  40. data/lib/betfair_api_ng_rails/api/parsers/list_market_catalogue.rb +15 -0
  41. data/lib/betfair_api_ng_rails/api/request_methods.rb +9 -1
  42. data/lib/betfair_api_ng_rails/errors.rb +7 -0
  43. data/lib/betfair_api_ng_rails/version.rb +1 -1
  44. data/lib/betfair_api_ng_rails.rb +41 -25
  45. data/spec/betfair_api_ng_rails/api/connection_spec.rb +3 -1
  46. data/spec/betfair_api_ng_rails/api/data/competition_result_spec.rb +15 -0
  47. data/spec/betfair_api_ng_rails/api/data/competition_spec.rb +7 -0
  48. data/spec/betfair_api_ng_rails/api/data/concerns/attributable_spec.rb +156 -0
  49. data/spec/betfair_api_ng_rails/api/data/concerns/hashable_spec.rb +44 -0
  50. data/spec/betfair_api_ng_rails/api/data/concerns/jsonable_spec.rb +170 -0
  51. data/spec/betfair_api_ng_rails/api/data/country_code_result_spec.rb +7 -0
  52. data/spec/betfair_api_ng_rails/api/data/event_result_spec.rb +16 -0
  53. data/spec/betfair_api_ng_rails/api/data/event_spec.rb +7 -0
  54. data/spec/betfair_api_ng_rails/api/data/event_type_result_spec.rb +16 -0
  55. data/spec/betfair_api_ng_rails/api/data/event_type_spec.rb +7 -0
  56. data/spec/betfair_api_ng_rails/api/data/ex_best_offers_overrides_spec.rb +7 -0
  57. data/spec/betfair_api_ng_rails/api/data/exchange_prices_spec.rb +15 -0
  58. data/spec/betfair_api_ng_rails/api/data/market_book_spec.rb +15 -0
  59. data/spec/betfair_api_ng_rails/api/data/market_catalogue_spec.rb +39 -0
  60. data/spec/betfair_api_ng_rails/api/data/market_description_spec.rb +7 -0
  61. data/spec/betfair_api_ng_rails/api/data/market_filter_spec.rb +7 -0
  62. data/spec/betfair_api_ng_rails/api/data/market_type_result_spec.rb +7 -0
  63. data/spec/betfair_api_ng_rails/api/data/match_spec.rb +7 -0
  64. data/spec/betfair_api_ng_rails/api/data/order_spec.rb +7 -0
  65. data/spec/betfair_api_ng_rails/api/data/price_projection_spec.rb +15 -0
  66. data/spec/betfair_api_ng_rails/api/data/price_size_spec.rb +7 -0
  67. data/spec/betfair_api_ng_rails/api/data/runner_catalog_spec.rb +7 -0
  68. data/spec/betfair_api_ng_rails/api/data/runner_spec.rb +33 -0
  69. data/spec/betfair_api_ng_rails/api/data/starting_prices_spec.rb +7 -0
  70. data/spec/betfair_api_ng_rails/api/data/time_range_result_spec.rb +17 -0
  71. data/spec/betfair_api_ng_rails/api/data/time_range_spec.rb +7 -0
  72. data/spec/betfair_api_ng_rails/api/data/venue_result_spec.rb +7 -0
  73. data/spec/betfair_api_ng_rails/api/hashalator_spec.rb +34 -4
  74. data/spec/betfair_api_ng_rails/api/request_methods_spec.rb +20 -0
  75. data/spec/betfair_api_ng_rails/integration/list_market_book_spec.rb +19 -0
  76. data/spec/betfair_api_ng_rails/integration/list_market_catalogue_spec.rb +36 -0
  77. data/spec/support/base_yaml_loader.rb +21 -0
  78. data/spec/support/data/models.yml +205 -0
  79. data/spec/support/data_models_yaml_loader.rb +7 -0
  80. data/spec/support/helper.rb +9 -0
  81. data/spec/support/shared_examples/data_model.rb +35 -0
  82. data/spec/support/shared_examples/simple_list_filtering_request.rb +3 -1
  83. metadata +100 -18
  84. data/lib/betfair_api_ng_rails/api/data/attributes.rb +0 -50
@@ -0,0 +1,205 @@
1
+ competition: &competition
2
+ id: '1'
3
+ name: World Cup 2014
4
+
5
+ competitionResult:
6
+ marketCount: '1'
7
+ competitionRegion: UA
8
+ competition:
9
+ <<: *competition
10
+
11
+ countryCodeResult:
12
+ marketCount: '1'
13
+ countryCode: 'UA'
14
+
15
+ event: &event
16
+ id: '1'
17
+ name: 'Chelse - PSG'
18
+ timezone: 'TZ'
19
+ countryCode: 'UA'
20
+ venue: 'Madrid'
21
+ openDate: '24-04-2014'
22
+
23
+ eventResult:
24
+ marketCount: 1
25
+ event:
26
+ <<: *event
27
+
28
+ eventType: &eventType
29
+ id: 1
30
+ name: 'Soccer'
31
+
32
+ eventTypeResult:
33
+ marketCount: 1
34
+ eventType:
35
+ <<: *eventType
36
+
37
+ exBestOffersOverrides: &exBestOffersOverrides
38
+ bestPricesDepth: 'depth'
39
+ rollupModel: 'model'
40
+ rollupLimit: 'limit'
41
+ rollupLiabilityThreshold: 'threshold'
42
+ rollupLiabilityFactor: 'factor'
43
+
44
+ priceSize: &priceSize
45
+ price: '2'
46
+ size: '3'
47
+
48
+ exchangePrices: &exchangePrices
49
+ availableToBack:
50
+ - <<: *priceSize
51
+ availableToLay:
52
+ - <<: *priceSize
53
+ tradedVolume:
54
+ - <<: *priceSize
55
+
56
+ timeRange: &timeRange
57
+ from: '23-04-2014'
58
+ to: '24-04-2014'
59
+
60
+ timeRangeResult:
61
+ marketCount: '1'
62
+ timeRange:
63
+ <<: *timeRange
64
+
65
+ venueResult:
66
+ marketCount: '1'
67
+ venue: 'Madrid'
68
+
69
+ startingPrices: &startingPrices
70
+ nearPrice: '1'
71
+ farPrice: '2'
72
+ backStakeTaken:
73
+ - <<: *priceSize
74
+ layLiabilityTaken:
75
+ - <<: *priceSize
76
+ actualSP: '123'
77
+
78
+ runnerCatalog: &runnerCatalog
79
+ selectionId: '123'
80
+ runnerName: 'name'
81
+ handicap: '1'
82
+ sortPriority: '2'
83
+ metadata: '3'
84
+
85
+ priceProjection:
86
+ priceData: '1'
87
+ exBestOffersOverrides:
88
+ <<: *exBestOffersOverrides
89
+ virtualise: '2'
90
+ rolloverStakes: '3'
91
+
92
+ marketTypeResult:
93
+ marketCount: '1'
94
+ marketType: 'MATCH'
95
+
96
+ match: &match
97
+ betId: '1'
98
+ matchId: '2'
99
+ side: '3'
100
+ price: '3'
101
+ size: '4'
102
+ matchDate: '121'
103
+
104
+ order: &order
105
+ betId: '1'
106
+ orderType: '2'
107
+ status: '12'
108
+ persistenceType: '3'
109
+ side: '2'
110
+ price: '4'
111
+ size: '3'
112
+ bspLiability: '12'
113
+ placedDate: '121'
114
+ avgPriceMatched: 'some'
115
+ sizeMatched: 'some'
116
+ sizeRemaining: 'some'
117
+ sizeLapsed: 'some'
118
+ sizeCancelled: 'some'
119
+ sizeVoided: 'some'
120
+
121
+ marketFilter:
122
+ textQuery: 'some'
123
+ exchangeIds: 'some'
124
+ eventTypeIds: 'some'
125
+ eventIds: 'some'
126
+ competitionIds: 'some'
127
+ venues: 'some'
128
+ bspOnly: 'some'
129
+ turnInPlayEnabled: 'some'
130
+ inPlayOnly: 'some'
131
+ marketBettingTypes: 'some'
132
+ marketCountries: 'some'
133
+ marketTypeCodes: 'some'
134
+ marketStartTime: 'some'
135
+ withOrders: 'some'
136
+
137
+ marketDescription: &marketDescription
138
+ persistenceEnabled: 'dqwdqw'
139
+ bspMarket: 'qwdqwd'
140
+ marketTime: 'adqwd'
141
+ suspendTime: 'adqwd'
142
+ settleTime: 'adqwd'
143
+ bettingType: 'afqwfw'
144
+ turnInPlayEnabled: 'qdqwd'
145
+ marketType: 'MATCH_ODDS'
146
+ regulator: 'qwdqwd'
147
+ marketBaseRate: 'dqwd'
148
+ discountAllowed: 'adqwdw'
149
+ wallet: 'adqwdw'
150
+ rules: 'wefewfwe'
151
+ rulesHasDate: '34'
152
+ clarifications: '123'
153
+
154
+ runner: &runner
155
+ selectionId: '123'
156
+ handicap: '3'
157
+ status: 'active'
158
+ adjustmentFactor: '1.2'
159
+ lastPriceTraded: '125.4'
160
+ totalMatched: '1235.34'
161
+ removalDate: '23-04-2014'
162
+ sp:
163
+ <<: *startingPrices
164
+ ex:
165
+ <<: *exchangePrices
166
+ orders:
167
+ - <<: *order
168
+ matches:
169
+ - <<: *match
170
+
171
+ marketBook:
172
+ marketId: '123'
173
+ isMarketDataDelayed: 'adwqd'
174
+ status: 'dqwdqw'
175
+ betDelay: 'dqwd'
176
+ bspReconciled: 'dqwd'
177
+ complete: 'adqwd'
178
+ inplay: 'dqwdqw'
179
+ numberOfRunners: 'qdqw'
180
+ numberOfWinners: 'qdqwd'
181
+ numberOfActiveRunners: 'dwqwd'
182
+ lastMatchTime: 'qdqw'
183
+ totalMatched: 'qwdwq'
184
+ totalAvailable: 'adqwd'
185
+ crossMatching: 'wdqwdqw'
186
+ runnersVoidable: 'adqwdw'
187
+ version: '123'
188
+ runners:
189
+ - <<: *runner
190
+
191
+ marketCatalogue:
192
+ marketId: '123'
193
+ marketName: 'name'
194
+ marketStartTime: '23-04-2014'
195
+ totalMatched: '123.4'
196
+ description:
197
+ <<: *marketDescription
198
+ runners:
199
+ - <<: *runnerCatalog
200
+ eventType:
201
+ <<: *eventType
202
+ competition:
203
+ <<: *competition
204
+ event:
205
+ <<: *event
@@ -0,0 +1,7 @@
1
+ class DataModelsYamlLoader < BaseYamlLoader
2
+
3
+ def initialize
4
+ super 'models'
5
+ end
6
+
7
+ end
@@ -0,0 +1,9 @@
1
+ class Helper
2
+ class << self
3
+
4
+ def key_to_attribute(key)
5
+ key.to_s.gsub(/^([a-z])/) { $1.capitalize }.scan(/[A-Z][a-z]*/).join("_").downcase
6
+ end
7
+
8
+ end
9
+ end
@@ -0,0 +1,35 @@
1
+ shared_examples 'data model' do |resourceHash|
2
+
3
+ let(:json) { resourceHash }
4
+ let(:data) { described_class.from_json(json) }
5
+
6
+ subject { data }
7
+
8
+ describe "loading from json" do
9
+
10
+ it { is_expected.to be_kind_of described_class }
11
+
12
+ resourceHash.each do |k, v|
13
+ next unless v.is_a?(String)
14
+
15
+ its(Helper.key_to_attribute(k)) { is_expected.to eq v }
16
+
17
+ end
18
+
19
+ end
20
+
21
+ if described_class.method_defined?(:to_hash)
22
+
23
+ describe "serialize to hash" do
24
+
25
+ subject { data.to_hash }
26
+
27
+ it { is_expected.to be_kind_of Hash }
28
+
29
+ it { is_expected.to eq json }
30
+
31
+ end
32
+
33
+ end
34
+
35
+ end
@@ -22,7 +22,9 @@ shared_examples 'simple list filtering request' do |method|
22
22
 
23
23
  let(:result_hash) { "{\"error\":{\"code\":-32700,\"message\":\"DSC-3000\"}}" }
24
24
 
25
- it { is_expected.to be_empty }
25
+ it "raise APINGException" do
26
+ expect{ subject }.to raise_error
27
+ end
26
28
 
27
29
  end
28
30
 
metadata CHANGED
@@ -1,97 +1,97 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: betfair_api_ng_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - sergio1990
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-04-19 00:00:00.000000000 Z
11
+ date: 2014-04-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ~>
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.3'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - "~>"
24
+ - - ~>
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.3'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
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: :development
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
42
  name: activesupport
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ">="
45
+ - - '>='
46
46
  - !ruby/object:Gem::Version
47
47
  version: 3.1.0
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - ">="
52
+ - - '>='
53
53
  - !ruby/object:Gem::Version
54
54
  version: 3.1.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rspec
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - "~>"
59
+ - - ~>
60
60
  - !ruby/object:Gem::Version
61
61
  version: 3.0.0.beta
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - "~>"
66
+ - - ~>
67
67
  - !ruby/object:Gem::Version
68
68
  version: 3.0.0.beta
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: rspec-its
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - ">="
73
+ - - '>='
74
74
  - !ruby/object:Gem::Version
75
75
  version: '0'
76
76
  type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - ">="
80
+ - - '>='
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: pry-nav
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - ">="
87
+ - - '>='
88
88
  - !ruby/object:Gem::Version
89
89
  version: '0'
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - ">="
94
+ - - '>='
95
95
  - !ruby/object:Gem::Version
96
96
  version: '0'
97
97
  description: Betfair API-NG for Rails
@@ -101,7 +101,7 @@ executables: []
101
101
  extensions: []
102
102
  extra_rdoc_files: []
103
103
  files:
104
- - ".gitignore"
104
+ - .gitignore
105
105
  - Gemfile
106
106
  - LICENSE.txt
107
107
  - README.md
@@ -111,22 +111,36 @@ files:
111
111
  - lib/betfair_api_ng_rails/api/concerns/errorable.rb
112
112
  - lib/betfair_api_ng_rails/api/config.rb
113
113
  - lib/betfair_api_ng_rails/api/connection.rb
114
+ - lib/betfair_api_ng_rails/api/connection_ext/error_handling.rb
114
115
  - lib/betfair_api_ng_rails/api/connection_ext/formatting.rb
115
116
  - lib/betfair_api_ng_rails/api/connection_ext/parsing.rb
116
117
  - lib/betfair_api_ng_rails/api/constants.rb
117
- - lib/betfair_api_ng_rails/api/data/attributes.rb
118
118
  - lib/betfair_api_ng_rails/api/data/base.rb
119
119
  - lib/betfair_api_ng_rails/api/data/competition.rb
120
120
  - lib/betfair_api_ng_rails/api/data/competition_result.rb
121
+ - lib/betfair_api_ng_rails/api/data/concerns/attributable.rb
121
122
  - lib/betfair_api_ng_rails/api/data/concerns/hashable.rb
123
+ - lib/betfair_api_ng_rails/api/data/concerns/jsonable.rb
122
124
  - lib/betfair_api_ng_rails/api/data/constants.rb
123
125
  - lib/betfair_api_ng_rails/api/data/country_code_result.rb
124
126
  - lib/betfair_api_ng_rails/api/data/event.rb
125
127
  - lib/betfair_api_ng_rails/api/data/event_result.rb
126
128
  - lib/betfair_api_ng_rails/api/data/event_type.rb
127
129
  - lib/betfair_api_ng_rails/api/data/event_type_result.rb
130
+ - lib/betfair_api_ng_rails/api/data/ex_best_offers_overrides.rb
131
+ - lib/betfair_api_ng_rails/api/data/exchange_prices.rb
132
+ - lib/betfair_api_ng_rails/api/data/market_book.rb
133
+ - lib/betfair_api_ng_rails/api/data/market_catalogue.rb
134
+ - lib/betfair_api_ng_rails/api/data/market_description.rb
128
135
  - lib/betfair_api_ng_rails/api/data/market_filter.rb
129
136
  - lib/betfair_api_ng_rails/api/data/market_type_result.rb
137
+ - lib/betfair_api_ng_rails/api/data/match.rb
138
+ - lib/betfair_api_ng_rails/api/data/order.rb
139
+ - lib/betfair_api_ng_rails/api/data/price_projection.rb
140
+ - lib/betfair_api_ng_rails/api/data/price_size.rb
141
+ - lib/betfair_api_ng_rails/api/data/runner.rb
142
+ - lib/betfair_api_ng_rails/api/data/runner_catalog.rb
143
+ - lib/betfair_api_ng_rails/api/data/starting_prices.rb
130
144
  - lib/betfair_api_ng_rails/api/data/time_range.rb
131
145
  - lib/betfair_api_ng_rails/api/data/time_range_result.rb
132
146
  - lib/betfair_api_ng_rails/api/data/venue_result.rb
@@ -168,6 +182,8 @@ files:
168
182
  - lib/betfair_api_ng_rails/api/parsers/list_countries.rb
169
183
  - lib/betfair_api_ng_rails/api/parsers/list_event_types.rb
170
184
  - lib/betfair_api_ng_rails/api/parsers/list_events.rb
185
+ - lib/betfair_api_ng_rails/api/parsers/list_market_book.rb
186
+ - lib/betfair_api_ng_rails/api/parsers/list_market_catalogue.rb
171
187
  - lib/betfair_api_ng_rails/api/parsers/list_market_types.rb
172
188
  - lib/betfair_api_ng_rails/api/parsers/list_time_ranges.rb
173
189
  - lib/betfair_api_ng_rails/api/parsers/list_venues.rb
@@ -181,7 +197,33 @@ files:
181
197
  - lib/generators/betfair_api_ng_rails/install/templates/betfair_api_ng_rails.rb
182
198
  - lib/generators/betfair_api_ng_rails/install/templates/betfair_api_ng_rails.yml
183
199
  - spec/betfair_api_ng_rails/api/connection_spec.rb
200
+ - spec/betfair_api_ng_rails/api/data/competition_result_spec.rb
201
+ - spec/betfair_api_ng_rails/api/data/competition_spec.rb
202
+ - spec/betfair_api_ng_rails/api/data/concerns/attributable_spec.rb
184
203
  - spec/betfair_api_ng_rails/api/data/concerns/hashable_spec.rb
204
+ - spec/betfair_api_ng_rails/api/data/concerns/jsonable_spec.rb
205
+ - spec/betfair_api_ng_rails/api/data/country_code_result_spec.rb
206
+ - spec/betfair_api_ng_rails/api/data/event_result_spec.rb
207
+ - spec/betfair_api_ng_rails/api/data/event_spec.rb
208
+ - spec/betfair_api_ng_rails/api/data/event_type_result_spec.rb
209
+ - spec/betfair_api_ng_rails/api/data/event_type_spec.rb
210
+ - spec/betfair_api_ng_rails/api/data/ex_best_offers_overrides_spec.rb
211
+ - spec/betfair_api_ng_rails/api/data/exchange_prices_spec.rb
212
+ - spec/betfair_api_ng_rails/api/data/market_book_spec.rb
213
+ - spec/betfair_api_ng_rails/api/data/market_catalogue_spec.rb
214
+ - spec/betfair_api_ng_rails/api/data/market_description_spec.rb
215
+ - spec/betfair_api_ng_rails/api/data/market_filter_spec.rb
216
+ - spec/betfair_api_ng_rails/api/data/market_type_result_spec.rb
217
+ - spec/betfair_api_ng_rails/api/data/match_spec.rb
218
+ - spec/betfair_api_ng_rails/api/data/order_spec.rb
219
+ - spec/betfair_api_ng_rails/api/data/price_projection_spec.rb
220
+ - spec/betfair_api_ng_rails/api/data/price_size_spec.rb
221
+ - spec/betfair_api_ng_rails/api/data/runner_catalog_spec.rb
222
+ - spec/betfair_api_ng_rails/api/data/runner_spec.rb
223
+ - spec/betfair_api_ng_rails/api/data/starting_prices_spec.rb
224
+ - spec/betfair_api_ng_rails/api/data/time_range_result_spec.rb
225
+ - spec/betfair_api_ng_rails/api/data/time_range_spec.rb
226
+ - spec/betfair_api_ng_rails/api/data/venue_result_spec.rb
185
227
  - spec/betfair_api_ng_rails/api/formatters/js_tree_formatter_spec.rb
186
228
  - spec/betfair_api_ng_rails/api/hashalator_spec.rb
187
229
  - spec/betfair_api_ng_rails/api/provider_spec.rb
@@ -191,10 +233,17 @@ files:
191
233
  - spec/betfair_api_ng_rails/integration/list_countries_spec.rb
192
234
  - spec/betfair_api_ng_rails/integration/list_event_types_spec.rb
193
235
  - spec/betfair_api_ng_rails/integration/list_events_spec.rb
236
+ - spec/betfair_api_ng_rails/integration/list_market_book_spec.rb
237
+ - spec/betfair_api_ng_rails/integration/list_market_catalogue_spec.rb
194
238
  - spec/betfair_api_ng_rails/integration/list_market_types_spec.rb
195
239
  - spec/betfair_api_ng_rails/integration/list_time_ranges_spec.rb
196
240
  - spec/betfair_api_ng_rails/integration/list_venues_spec.rb
197
241
  - spec/spec_helper.rb
242
+ - spec/support/base_yaml_loader.rb
243
+ - spec/support/data/models.yml
244
+ - spec/support/data_models_yaml_loader.rb
245
+ - spec/support/helper.rb
246
+ - spec/support/shared_examples/data_model.rb
198
247
  - spec/support/shared_examples/request_method.rb
199
248
  - spec/support/shared_examples/simple_list_filtering_request.rb
200
249
  homepage: ''
@@ -207,12 +256,12 @@ require_paths:
207
256
  - lib
208
257
  required_ruby_version: !ruby/object:Gem::Requirement
209
258
  requirements:
210
- - - ">="
259
+ - - '>='
211
260
  - !ruby/object:Gem::Version
212
261
  version: '0'
213
262
  required_rubygems_version: !ruby/object:Gem::Requirement
214
263
  requirements:
215
- - - ">="
264
+ - - '>='
216
265
  - !ruby/object:Gem::Version
217
266
  version: '0'
218
267
  requirements: []
@@ -223,7 +272,33 @@ specification_version: 4
223
272
  summary: Provides accessing betfair.com api-ng using non-interactive login
224
273
  test_files:
225
274
  - spec/betfair_api_ng_rails/api/connection_spec.rb
275
+ - spec/betfair_api_ng_rails/api/data/competition_result_spec.rb
276
+ - spec/betfair_api_ng_rails/api/data/competition_spec.rb
277
+ - spec/betfair_api_ng_rails/api/data/concerns/attributable_spec.rb
226
278
  - spec/betfair_api_ng_rails/api/data/concerns/hashable_spec.rb
279
+ - spec/betfair_api_ng_rails/api/data/concerns/jsonable_spec.rb
280
+ - spec/betfair_api_ng_rails/api/data/country_code_result_spec.rb
281
+ - spec/betfair_api_ng_rails/api/data/event_result_spec.rb
282
+ - spec/betfair_api_ng_rails/api/data/event_spec.rb
283
+ - spec/betfair_api_ng_rails/api/data/event_type_result_spec.rb
284
+ - spec/betfair_api_ng_rails/api/data/event_type_spec.rb
285
+ - spec/betfair_api_ng_rails/api/data/ex_best_offers_overrides_spec.rb
286
+ - spec/betfair_api_ng_rails/api/data/exchange_prices_spec.rb
287
+ - spec/betfair_api_ng_rails/api/data/market_book_spec.rb
288
+ - spec/betfair_api_ng_rails/api/data/market_catalogue_spec.rb
289
+ - spec/betfair_api_ng_rails/api/data/market_description_spec.rb
290
+ - spec/betfair_api_ng_rails/api/data/market_filter_spec.rb
291
+ - spec/betfair_api_ng_rails/api/data/market_type_result_spec.rb
292
+ - spec/betfair_api_ng_rails/api/data/match_spec.rb
293
+ - spec/betfair_api_ng_rails/api/data/order_spec.rb
294
+ - spec/betfair_api_ng_rails/api/data/price_projection_spec.rb
295
+ - spec/betfair_api_ng_rails/api/data/price_size_spec.rb
296
+ - spec/betfair_api_ng_rails/api/data/runner_catalog_spec.rb
297
+ - spec/betfair_api_ng_rails/api/data/runner_spec.rb
298
+ - spec/betfair_api_ng_rails/api/data/starting_prices_spec.rb
299
+ - spec/betfair_api_ng_rails/api/data/time_range_result_spec.rb
300
+ - spec/betfair_api_ng_rails/api/data/time_range_spec.rb
301
+ - spec/betfair_api_ng_rails/api/data/venue_result_spec.rb
227
302
  - spec/betfair_api_ng_rails/api/formatters/js_tree_formatter_spec.rb
228
303
  - spec/betfair_api_ng_rails/api/hashalator_spec.rb
229
304
  - spec/betfair_api_ng_rails/api/provider_spec.rb
@@ -233,9 +308,16 @@ test_files:
233
308
  - spec/betfair_api_ng_rails/integration/list_countries_spec.rb
234
309
  - spec/betfair_api_ng_rails/integration/list_event_types_spec.rb
235
310
  - spec/betfair_api_ng_rails/integration/list_events_spec.rb
311
+ - spec/betfair_api_ng_rails/integration/list_market_book_spec.rb
312
+ - spec/betfair_api_ng_rails/integration/list_market_catalogue_spec.rb
236
313
  - spec/betfair_api_ng_rails/integration/list_market_types_spec.rb
237
314
  - spec/betfair_api_ng_rails/integration/list_time_ranges_spec.rb
238
315
  - spec/betfair_api_ng_rails/integration/list_venues_spec.rb
239
316
  - spec/spec_helper.rb
317
+ - spec/support/base_yaml_loader.rb
318
+ - spec/support/data/models.yml
319
+ - spec/support/data_models_yaml_loader.rb
320
+ - spec/support/helper.rb
321
+ - spec/support/shared_examples/data_model.rb
240
322
  - spec/support/shared_examples/request_method.rb
241
323
  - spec/support/shared_examples/simple_list_filtering_request.rb
@@ -1,50 +0,0 @@
1
- module BetfairApiNgRails
2
- module Api
3
- module Data
4
- module Attributes
5
-
6
- MARKET_FILTER_ATTRS = [
7
- :text_query,
8
- :exchange_ids,
9
- :event_type_ids,
10
- :event_ids,
11
- :competition_ids,
12
- :venues,
13
- :bsp_only,
14
- :turn_in_play_enabled,
15
- :in_play_only,
16
- :market_betting_types,
17
- :market_countries,
18
- :market_type_codes,
19
- :market_start_time,
20
- :with_orders
21
- ]
22
-
23
- COMPETITION_ATTRS = [
24
- :id,
25
- :name
26
- ]
27
-
28
- EVENT_TYPE_ATTRS = [
29
- :id,
30
- :name
31
- ]
32
-
33
- EVENT_ATTRS = [
34
- :id,
35
- :name,
36
- :timezone,
37
- :country_code,
38
- :venue,
39
- :open_date
40
- ]
41
-
42
- TIME_RANGE_ATTRS = [
43
- :from,
44
- :to
45
- ]
46
-
47
- end
48
- end
49
- end
50
- end