xml_soccer 0.0.1.pre1 → 0.0.1.pre2

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.
@@ -1,57 +1,57 @@
1
- <?xml version="1.0" encoding="utf-8"?>
2
- <Envelope>
3
- <Body>
4
- <GetHistoricMatchesByTeamsAndDateIntervalResponse>
5
- <GetHistoricMatchesByTeamsAndDateIntervalResult>
6
- <XMLSOCCER.COM>
7
- <Match>
8
- <Id>65805</Id>
9
- <FixtureMatch_Id>324725</FixtureMatch_Id>
10
- <Date>2014-01-04T07:00:00-08:00</Date>
11
- <Round>21</Round>
12
- <Spectators>3212</Spectators>
13
- <League>Scottish Premier League</League>
14
- <HomeTeam>Ross County</HomeTeam>
15
- <HomeTeam_Id>360</HomeTeam_Id>
16
- <HomeCorners>5</HomeCorners>
17
- <HomeGoals>1</HomeGoals>
18
- <HalfTimeHomeGoals>0</HalfTimeHomeGoals>
19
- <HomeShots>10</HomeShots>
20
- <HomeShotsOnTarget>2</HomeShotsOnTarget>
21
- <HomeFouls>13</HomeFouls>
22
- <HomeGoalDetails>88': Graham Carey;</HomeGoalDetails>
23
- <HomeLineupGoalkeeper> Michael Fraser</HomeLineupGoalkeeper>
24
- <HomeLineupDefense> Scott Boyd; Brian McLean; Ben Gordon; Evangelos Ikonomou;</HomeLineupDefense>
25
- <HomeLineupMidfield> Stuart Kettlewell; Alex Cooper; Richard Brittain; Graham Carey;</HomeLineupMidfield>
26
- <HomeLineupForward> Jordan Slew; Gary Glen;</HomeLineupForward>
27
- <HomeYellowCards>1</HomeYellowCards>
28
- <HomeRedCards>0</HomeRedCards>
29
- <HomeTeamFormation>4-4-2</HomeTeamFormation>
30
- <AwayTeam>St Johnstone</AwayTeam>
31
- <AwayTeam_Id>46</AwayTeam_Id>
32
- <AwayCorners>0</AwayCorners>
33
- <AwayGoals>0</AwayGoals>
34
- <HalfTimeAwayGoals>0</HalfTimeAwayGoals>
35
- <AwayShots>9</AwayShots>
36
- <AwayShotsOnTarget>3</AwayShotsOnTarget>
37
- <AwayFouls>14</AwayFouls>
38
- <AwayGoalDetails />
39
- <AwayLineupGoalkeeper> Alan Mannus</AwayLineupGoalkeeper>
40
- <AwayLineupDefense> Frazer Wright; Steven Anderson; Thomas Scobbie; David Mackay;</AwayLineupDefense>
41
- <AwayLineupMidfield> David Wotherspoon; Murray Davidson; Chris Millar; Gary McDonald;</AwayLineupMidfield>
42
- <AwayLineupForward> Nigel Hasselbaink; Steve May;</AwayLineupForward>
43
- <AwayYellowCards>1</AwayYellowCards>
44
- <AwayRedCards>0</AwayRedCards>
45
- <AwayTeamFormation>4-4-2</AwayTeamFormation>
46
- <HomeTeamYellowCardDetails>89': Scott Boyd;</HomeTeamYellowCardDetails>
47
- <AwayTeamYellowCardDetails>61': David Mackay;</AwayTeamYellowCardDetails>
48
- <HomeTeamRedCardDetails />
49
- <AwayTeamRedCardDetails />
50
- <HomeSubDetails>84': in Michael Tidser;84': out Jordan Slew;66': out Gary Glen;66': in Melvin de Leeuw;</HomeSubDetails>
51
- <AwaySubDetails>90': in Rory Fallon;90': in Lee Croft;90': out Chris Millar;90': out David Wotherspoon;69': out Nigel Hasselbaink;69': in Michael O'Halloran;</AwaySubDetails>
52
- </Match>
53
- </XMLSOCCER.COM>
54
- </GetHistoricMatchesByTeamsAndDateIntervalResult>
55
- </GetHistoricMatchesByTeamsAndDateIntervalResponse>
56
- </Body>
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <Envelope>
3
+ <Body>
4
+ <GetHistoricMatchesByTeamsAndDateIntervalResponse>
5
+ <GetHistoricMatchesByTeamsAndDateIntervalResult>
6
+ <XMLSOCCER.COM>
7
+ <Match>
8
+ <Id>65805</Id>
9
+ <FixtureMatch_Id>324725</FixtureMatch_Id>
10
+ <Date>2014-01-04T07:00:00-08:00</Date>
11
+ <Round>21</Round>
12
+ <Spectators>3212</Spectators>
13
+ <League>Scottish Premier League</League>
14
+ <HomeTeam>Ross County</HomeTeam>
15
+ <HomeTeam_Id>360</HomeTeam_Id>
16
+ <HomeCorners>5</HomeCorners>
17
+ <HomeGoals>1</HomeGoals>
18
+ <HalfTimeHomeGoals>0</HalfTimeHomeGoals>
19
+ <HomeShots>10</HomeShots>
20
+ <HomeShotsOnTarget>2</HomeShotsOnTarget>
21
+ <HomeFouls>13</HomeFouls>
22
+ <HomeGoalDetails>88': Graham Carey;</HomeGoalDetails>
23
+ <HomeLineupGoalkeeper> Michael Fraser</HomeLineupGoalkeeper>
24
+ <HomeLineupDefense> Scott Boyd; Brian McLean; Ben Gordon; Evangelos Ikonomou;</HomeLineupDefense>
25
+ <HomeLineupMidfield> Stuart Kettlewell; Alex Cooper; Richard Brittain; Graham Carey;</HomeLineupMidfield>
26
+ <HomeLineupForward> Jordan Slew; Gary Glen;</HomeLineupForward>
27
+ <HomeYellowCards>1</HomeYellowCards>
28
+ <HomeRedCards>0</HomeRedCards>
29
+ <HomeTeamFormation>4-4-2</HomeTeamFormation>
30
+ <AwayTeam>St Johnstone</AwayTeam>
31
+ <AwayTeam_Id>46</AwayTeam_Id>
32
+ <AwayCorners>0</AwayCorners>
33
+ <AwayGoals>0</AwayGoals>
34
+ <HalfTimeAwayGoals>0</HalfTimeAwayGoals>
35
+ <AwayShots>9</AwayShots>
36
+ <AwayShotsOnTarget>3</AwayShotsOnTarget>
37
+ <AwayFouls>14</AwayFouls>
38
+ <AwayGoalDetails />
39
+ <AwayLineupGoalkeeper> Alan Mannus</AwayLineupGoalkeeper>
40
+ <AwayLineupDefense> Frazer Wright; Steven Anderson; Thomas Scobbie; David Mackay;</AwayLineupDefense>
41
+ <AwayLineupMidfield> David Wotherspoon; Murray Davidson; Chris Millar; Gary McDonald;</AwayLineupMidfield>
42
+ <AwayLineupForward> Nigel Hasselbaink; Steve May;</AwayLineupForward>
43
+ <AwayYellowCards>1</AwayYellowCards>
44
+ <AwayRedCards>0</AwayRedCards>
45
+ <AwayTeamFormation>4-4-2</AwayTeamFormation>
46
+ <HomeTeamYellowCardDetails>89': Scott Boyd;</HomeTeamYellowCardDetails>
47
+ <AwayTeamYellowCardDetails>61': David Mackay;</AwayTeamYellowCardDetails>
48
+ <HomeTeamRedCardDetails />
49
+ <AwayTeamRedCardDetails />
50
+ <HomeSubDetails>84': in Michael Tidser;84': out Jordan Slew;66': out Gary Glen;66': in Melvin de Leeuw;</HomeSubDetails>
51
+ <AwaySubDetails>90': in Rory Fallon;90': in Lee Croft;90': out Chris Millar;90': out David Wotherspoon;69': out Nigel Hasselbaink;69': in Michael O'Halloran;</AwaySubDetails>
52
+ </Match>
53
+ </XMLSOCCER.COM>
54
+ </GetHistoricMatchesByTeamsAndDateIntervalResult>
55
+ </GetHistoricMatchesByTeamsAndDateIntervalResponse>
56
+ </Body>
57
57
  </Envelope>
@@ -38,13 +38,13 @@ describe XmlSoccer do
38
38
  @array = @client.leagues
39
39
  end
40
40
 
41
- it 'returns an array' do
42
- expect(@array).to be_an_instance_of(Array)
43
- end
44
-
45
- it 'returns expected leagues' do
46
- expect(@array).to include(HashedResponses::GetAllLeagues)
47
- end
41
+ it 'returns an array' do
42
+ expect(@array).to be_an_instance_of(Array)
43
+ end
44
+
45
+ it 'returns expected leagues' do
46
+ expect(@array).to include(HashedResponses::GetAllLeagues)
47
+ end
48
48
  end
49
49
 
50
50
  describe '#teams' do
@@ -69,11 +69,11 @@ describe XmlSoccer do
69
69
  describe '#teams_in_league_by_season' do
70
70
  before do
71
71
  message = {"ApiKey" => "testkey",
72
- "league" => "English Premier League", "seasonDateString" => "1011"}
72
+ "league" => "English Premier League", "seasonDateString" => "1213"}
73
73
  fixture = File.read("spec/fixtures/get_all_teams_by_league_and_season.xml")
74
74
  response = {code: 200, headers: {}, body: fixture}
75
75
  savon.expects(:get_all_teams_by_league_and_season).with(message: message).returns(response)
76
- @array = @client.teams_in_league_by_season(league: "English Premier League", season: "1011")
76
+ @array = @client.teams_in_league_by_season(league: "English Premier League", season: "1213")
77
77
  end
78
78
 
79
79
  it 'returns an array' do
@@ -97,6 +97,10 @@ describe XmlSoccer do
97
97
  @array = @client.fixtures_by_date(start_date: Date.new(2014,1,3), end_date: Date.new(2014,1,6))
98
98
  end
99
99
 
100
+ it 'returns an array' do
101
+ expect(@array).to be_an_instance_of(Array)
102
+ end
103
+
100
104
  it 'returns expected fixtures' do
101
105
  expect(@array).to include(HashedResponses::GetFixturesByDateInterval)
102
106
  end
@@ -113,6 +117,10 @@ describe XmlSoccer do
113
117
  savon.expects(:get_fixtures_by_date_interval_and_league).with(message: message).returns(response)
114
118
  @array = @client.fixtures_by_date_and_league(league: "Scottish Premier League", start_date: Date.new(2014,1,3), end_date: Date.new(2014,1,6))
115
119
  end
120
+
121
+ it 'returns an array' do
122
+ expect(@array).to be_an_instance_of(Array)
123
+ end
116
124
 
117
125
  it 'returns expected fixtures' do
118
126
  expect(@array).to include(HashedResponses::GetFixturesByDateIntervalAndLeague)
@@ -130,6 +138,10 @@ describe XmlSoccer do
130
138
  savon.expects(:get_fixtures_by_date_interval_and_team).with(message: message).returns(response)
131
139
  @array = @client.fixtures_by_date_and_team(team: "Ross County", start_date: Date.new(2014,1,3), end_date: Date.new(2014,1,6))
132
140
  end
141
+
142
+ it 'returns an array' do
143
+ expect(@array).to be_an_instance_of(Array)
144
+ end
133
145
 
134
146
  it 'returns expected fixtures' do
135
147
  expect(@array).to include(HashedResponses::GetFixturesByDateIntervalAndTeam)
@@ -145,6 +157,10 @@ describe XmlSoccer do
145
157
  savon.expects(:get_historic_matches_by_fixture_match_id).with(message: message).returns(response)
146
158
  @array = @client.historic_match_by_fixture(fixture_id: "324725")
147
159
  end
160
+
161
+ it 'returns an array' do
162
+ expect(@array).to be_an_instance_of(Array)
163
+ end
148
164
 
149
165
  it 'returns expected match' do
150
166
  expect(@array).to include(HashedResponses::GetHistoricMatchesByFixtureMatchId)
@@ -160,6 +176,10 @@ describe XmlSoccer do
160
176
  savon.expects(:get_historic_matches_by_id).with(message: message).returns(response)
161
177
  @array = @client.historic_match(match_id: "65805")
162
178
  end
179
+
180
+ it 'returns an array' do
181
+ expect(@array).to be_an_instance_of(Array)
182
+ end
163
183
 
164
184
  it 'returns expected match' do
165
185
  expect(@array).to include(HashedResponses::GetHistoricMatchesById)
@@ -178,6 +198,10 @@ describe XmlSoccer do
178
198
  @array = @client.historic_matches_by_league_and_date(league: "Scottish Premier League", start_date: Date.new(2014, 1, 3), end_date: Date.new(2014, 1, 6))
179
199
  end
180
200
 
201
+ it 'returns an array' do
202
+ expect(@array).to be_an_instance_of(Array)
203
+ end
204
+
181
205
  it 'returns expected match' do
182
206
  expect(@array).to include(HashedResponses::GetHistoricMatchesByLeagueAndDateInterval)
183
207
  end
@@ -193,6 +217,10 @@ describe XmlSoccer do
193
217
  savon.expects(:get_historic_matches_by_league_and_season).with(message: message).returns(response)
194
218
  @array = @client.historic_matches_by_league_and_season(league: "Scottish Premier League", season: "")
195
219
  end
220
+
221
+ it 'returns an array' do
222
+ expect(@array).to be_an_instance_of(Array)
223
+ end
196
224
 
197
225
  it 'returns expected match' do
198
226
  expect(@array).to include(HashedResponses::GetHistoricMatchesByLeagueAndSeason)
@@ -211,6 +239,10 @@ describe XmlSoccer do
211
239
  @array = @client.historic_matches_by_team_and_date(team: "360", start_date: Date.new(2014,1,3), end_date: Date.new(2014,1,6))
212
240
  end
213
241
 
242
+ it 'returns an array' do
243
+ expect(@array).to be_an_instance_of(Array)
244
+ end
245
+
214
246
  it 'returns expected match' do
215
247
  expect(@array).to include(HashedResponses::GetHistoricMatchesByTeamAndDateInterval)
216
248
  end
@@ -228,6 +260,10 @@ describe XmlSoccer do
228
260
  savon.expects(:get_historic_matches_by_teams_and_date_interval).with(message: message).returns(response)
229
261
  @array = @client.historic_matches_by_teams_and_date(team_1: "Ross County", team_2: "St Johnstone", start_date: Date.new(2014,1,3), end_date: Date.new(2014,1,6))
230
262
  end
263
+
264
+ it 'returns an array' do
265
+ expect(@array).to be_an_instance_of(Array)
266
+ end
231
267
 
232
268
  it 'returns expected match' do
233
269
  expect(@array).to include(HashedResponses::GetHistoricMatchesByTeamsAndDateInterval)
data/xml_soccer.gemspec CHANGED
@@ -23,5 +23,5 @@ Gem::Specification.new do |gem|
23
23
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
24
24
  gem.name = "xml_soccer"
25
25
  gem.require_paths = ["lib"]
26
- gem.version = "0.0.1.pre1"
26
+ gem.version = "0.0.1.pre2"
27
27
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xml_soccer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1.pre1
4
+ version: 0.0.1.pre2
5
5
  prerelease: 6
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-02-27 00:00:00.000000000 Z
12
+ date: 2014-02-28 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: savon