songkickr 0.2.2 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +6 -2
- data/Gemfile.lock +32 -10
- data/README.rdoc +7 -7
- data/Rakefile +1 -1
- data/VERSION +1 -1
- data/bin/autospec +16 -0
- data/bin/convert_to_should_syntax +16 -0
- data/bin/guard +16 -0
- data/bin/htmldiff +16 -0
- data/bin/httparty +16 -0
- data/bin/jeweler +16 -0
- data/bin/ldiff +16 -0
- data/bin/rake +16 -0
- data/bin/rake2thor +16 -0
- data/bin/rg +16 -0
- data/bin/ri +16 -0
- data/bin/rspec +16 -0
- data/bin/thor +16 -0
- data/doc/APIError.html +241 -0
- data/doc/APIKeyNotSet.html +164 -175
- data/doc/LICENSE.html +109 -109
- data/doc/README_rdoc.html +120 -117
- data/doc/ResourceNotFound.html +203 -0
- data/doc/Songkickr/Artist.html +210 -237
- data/doc/Songkickr/ArtistResult.html +228 -254
- data/doc/Songkickr/ConcertSetlistResult.html +205 -223
- data/doc/Songkickr/Event.html +344 -409
- data/doc/Songkickr/EventResult.html +226 -252
- data/doc/Songkickr/Location.html +210 -237
- data/doc/Songkickr/LocationResult.html +229 -255
- data/doc/Songkickr/Performance.html +222 -253
- data/doc/Songkickr/Remote.html +630 -481
- data/doc/Songkickr/Setlist.html +258 -296
- data/doc/Songkickr/SetlistItem.html +187 -206
- data/doc/Songkickr/Venue.html +205 -232
- data/doc/Songkickr.html +204 -271
- data/doc/created.rid +16 -16
- data/doc/images/add.png +0 -0
- data/doc/images/delete.png +0 -0
- data/doc/images/tag_blue.png +0 -0
- data/doc/images/transparent.png +0 -0
- data/doc/index.html +93 -127
- data/doc/js/darkfish.js +99 -62
- data/doc/js/jquery.js +15 -29
- data/doc/js/navigation.js +142 -0
- data/doc/js/search.js +94 -0
- data/doc/js/search_index.js +1 -0
- data/doc/js/searcher.js +228 -0
- data/doc/rdoc.css +119 -339
- data/doc/table_of_contents.html +185 -0
- data/lib/songkickr/artist.rb +3 -3
- data/lib/songkickr/remote.rb +36 -13
- data/lib/songkickr.rb +16 -2
- data/songkickr.gemspec +121 -4
- data/test/fixtures/vcr/invalid_api_key.yml +63 -0
- data/test/fixtures/vcr/invalid_event_id.yml +33 -0
- data/test/fixtures/vcr/invalid_user.yml +32 -0
- data/test/fixtures/vcr/invalid_venue_id.yml +33 -0
- data/test/fixtures/vcr/valid_event.yml +52 -0
- data/test/fixtures/vcr/valid_user.yml +71 -0
- data/test/fixtures/vcr/valid_venue.yml +53 -0
- data/test/helper.rb +2 -2
- data/test/songkickr/test_remote.rb +68 -24
- data/test/vcr_helper.rb +7 -0
- data/test.rb +2 -2
- metadata +626 -40
@@ -0,0 +1,185 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
|
3
|
+
<html>
|
4
|
+
<head>
|
5
|
+
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
|
6
|
+
|
7
|
+
<title>Table of Contents - RDoc Documentation</title>
|
8
|
+
|
9
|
+
<link type="text/css" media="screen" href="./rdoc.css" rel="stylesheet">
|
10
|
+
|
11
|
+
<script type="text/javascript">
|
12
|
+
var rdoc_rel_prefix = "./";
|
13
|
+
</script>
|
14
|
+
|
15
|
+
<script type="text/javascript" charset="utf-8" src="./js/jquery.js"></script>
|
16
|
+
<script type="text/javascript" charset="utf-8" src="./js/navigation.js"></script>
|
17
|
+
<script type="text/javascript" charset="utf-8" src="./js/search_index.js"></script>
|
18
|
+
<script type="text/javascript" charset="utf-8" src="./js/search.js"></script>
|
19
|
+
<script type="text/javascript" charset="utf-8" src="./js/searcher.js"></script>
|
20
|
+
<script type="text/javascript" charset="utf-8" src="./js/darkfish.js"></script>
|
21
|
+
|
22
|
+
|
23
|
+
<body class="indexpage">
|
24
|
+
<h1>Table of Contents - RDoc Documentation</h1>
|
25
|
+
|
26
|
+
<h2>Pages</h2>
|
27
|
+
<ul>
|
28
|
+
<li class="file">
|
29
|
+
<a href="LICENSE.html">LICENSE</a>
|
30
|
+
</li>
|
31
|
+
<li class="file">
|
32
|
+
<a href="README_rdoc.html">README</a>
|
33
|
+
|
34
|
+
<img class="toc-toggle" src="images/transparent.png" alt="" title="toggle headings">
|
35
|
+
<ul class="initially-hidden">
|
36
|
+
<li><a href="README_rdoc.html#label-songkickr">songkickr</a>
|
37
|
+
<li><a href="README_rdoc.html#label-Install+Instructions">Install Instructions</a>
|
38
|
+
<li><a href="README_rdoc.html#label-Usage+Instructions">Usage Instructions</a>
|
39
|
+
<li><a href="README_rdoc.html#label-Note+on+Patches%2FPull+Requests">Note on Patches/Pull Requests</a>
|
40
|
+
<li><a href="README_rdoc.html#label-Copyright">Copyright</a>
|
41
|
+
<li><a href="README_rdoc.html#label-Thanks">Thanks</a>
|
42
|
+
</ul>
|
43
|
+
</li>
|
44
|
+
|
45
|
+
</ul>
|
46
|
+
|
47
|
+
<h2 id="classes">Classes/Modules</h2>
|
48
|
+
<ul>
|
49
|
+
<li class="module">
|
50
|
+
<a href="Songkickr.html">Songkickr</a>
|
51
|
+
</li>
|
52
|
+
<li class="class">
|
53
|
+
<a href="Songkickr/Artist.html">Songkickr::Artist</a>
|
54
|
+
</li>
|
55
|
+
<li class="class">
|
56
|
+
<a href="Songkickr/ArtistResult.html">Songkickr::ArtistResult</a>
|
57
|
+
</li>
|
58
|
+
<li class="class">
|
59
|
+
<a href="Songkickr/ConcertSetlistResult.html">Songkickr::ConcertSetlistResult</a>
|
60
|
+
</li>
|
61
|
+
<li class="class">
|
62
|
+
<a href="Songkickr/Event.html">Songkickr::Event</a>
|
63
|
+
</li>
|
64
|
+
<li class="class">
|
65
|
+
<a href="Songkickr/EventResult.html">Songkickr::EventResult</a>
|
66
|
+
</li>
|
67
|
+
<li class="class">
|
68
|
+
<a href="Songkickr/Location.html">Songkickr::Location</a>
|
69
|
+
</li>
|
70
|
+
<li class="class">
|
71
|
+
<a href="Songkickr/LocationResult.html">Songkickr::LocationResult</a>
|
72
|
+
</li>
|
73
|
+
<li class="class">
|
74
|
+
<a href="Songkickr/Performance.html">Songkickr::Performance</a>
|
75
|
+
</li>
|
76
|
+
<li class="class">
|
77
|
+
<a href="Songkickr/Remote.html">Songkickr::Remote</a>
|
78
|
+
</li>
|
79
|
+
<li class="class">
|
80
|
+
<a href="Songkickr/Setlist.html">Songkickr::Setlist</a>
|
81
|
+
</li>
|
82
|
+
<li class="class">
|
83
|
+
<a href="Songkickr/SetlistItem.html">Songkickr::SetlistItem</a>
|
84
|
+
</li>
|
85
|
+
<li class="class">
|
86
|
+
<a href="Songkickr/Venue.html">Songkickr::Venue</a>
|
87
|
+
</li>
|
88
|
+
<li class="class">
|
89
|
+
<a href="APIError.html">APIError</a>
|
90
|
+
</li>
|
91
|
+
<li class="class">
|
92
|
+
<a href="APIKeyNotSet.html">APIKeyNotSet</a>
|
93
|
+
</li>
|
94
|
+
<li class="class">
|
95
|
+
<a href="ResourceNotFound.html">ResourceNotFound</a>
|
96
|
+
</li>
|
97
|
+
|
98
|
+
</ul>
|
99
|
+
|
100
|
+
<h2 id="methods">Methods</h2>
|
101
|
+
<ul>
|
102
|
+
|
103
|
+
<li class="method"><a href="Songkickr.html#method-c-api_key">::api_key — Songkickr</a>
|
104
|
+
|
105
|
+
<li class="method"><a href="Songkickr.html#method-c-api_key-3D">::api_key= — Songkickr</a>
|
106
|
+
|
107
|
+
<li class="method"><a href="Songkickr/SetlistItem.html#method-c-new">::new — Songkickr::SetlistItem</a>
|
108
|
+
|
109
|
+
<li class="method"><a href="Songkickr/ConcertSetlistResult.html#method-c-new">::new — Songkickr::ConcertSetlistResult</a>
|
110
|
+
|
111
|
+
<li class="method"><a href="APIError.html#method-c-new">::new — APIError</a>
|
112
|
+
|
113
|
+
<li class="method"><a href="Songkickr/Event.html#method-c-new">::new — Songkickr::Event</a>
|
114
|
+
|
115
|
+
<li class="method"><a href="Songkickr/Venue.html#method-c-new">::new — Songkickr::Venue</a>
|
116
|
+
|
117
|
+
<li class="method"><a href="Songkickr/ArtistResult.html#method-c-new">::new — Songkickr::ArtistResult</a>
|
118
|
+
|
119
|
+
<li class="method"><a href="Songkickr/EventResult.html#method-c-new">::new — Songkickr::EventResult</a>
|
120
|
+
|
121
|
+
<li class="method"><a href="Songkickr/Setlist.html#method-c-new">::new — Songkickr::Setlist</a>
|
122
|
+
|
123
|
+
<li class="method"><a href="Songkickr/Location.html#method-c-new">::new — Songkickr::Location</a>
|
124
|
+
|
125
|
+
<li class="method"><a href="Songkickr/LocationResult.html#method-c-new">::new — Songkickr::LocationResult</a>
|
126
|
+
|
127
|
+
<li class="method"><a href="Songkickr/Remote.html#method-c-new">::new — Songkickr::Remote</a>
|
128
|
+
|
129
|
+
<li class="method"><a href="Songkickr/Performance.html#method-c-new">::new — Songkickr::Performance</a>
|
130
|
+
|
131
|
+
<li class="method"><a href="Songkickr/Artist.html#method-c-new">::new — Songkickr::Artist</a>
|
132
|
+
|
133
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-artist_events">#artist_events — Songkickr::Remote</a>
|
134
|
+
|
135
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-artist_search">#artist_search — Songkickr::Remote</a>
|
136
|
+
|
137
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-concert_setlists">#concert_setlists — Songkickr::Remote</a>
|
138
|
+
|
139
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-event">#event — Songkickr::Remote</a>
|
140
|
+
|
141
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-events">#events — Songkickr::Remote</a>
|
142
|
+
|
143
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-get">#get — Songkickr::Remote</a>
|
144
|
+
|
145
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-gigography">#gigography — Songkickr::Remote</a>
|
146
|
+
|
147
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-location_search">#location_search — Songkickr::Remote</a>
|
148
|
+
|
149
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-metro_areas_events">#metro_areas_events — Songkickr::Remote</a>
|
150
|
+
|
151
|
+
<li class="method"><a href="Songkickr/Event.html#method-i-parse_performance">#parse_performance — Songkickr::Event</a>
|
152
|
+
|
153
|
+
<li class="method"><a href="Songkickr/ArtistResult.html#method-i-parse_results">#parse_results — Songkickr::ArtistResult</a>
|
154
|
+
|
155
|
+
<li class="method"><a href="Songkickr/ConcertSetlistResult.html#method-i-parse_results">#parse_results — Songkickr::ConcertSetlistResult</a>
|
156
|
+
|
157
|
+
<li class="method"><a href="Songkickr/EventResult.html#method-i-parse_results">#parse_results — Songkickr::EventResult</a>
|
158
|
+
|
159
|
+
<li class="method"><a href="Songkickr/LocationResult.html#method-i-parse_results">#parse_results — Songkickr::LocationResult</a>
|
160
|
+
|
161
|
+
<li class="method"><a href="Songkickr/Setlist.html#method-i-parse_setlist_items">#parse_setlist_items — Songkickr::Setlist</a>
|
162
|
+
|
163
|
+
<li class="method"><a href="Songkickr/Event.html#method-i-start_hash_to_datetime">#start_hash_to_datetime — Songkickr::Event</a>
|
164
|
+
|
165
|
+
<li class="method"><a href="APIKeyNotSet.html#method-i-to_s">#to_s — APIKeyNotSet</a>
|
166
|
+
|
167
|
+
<li class="method"><a href="ResourceNotFound.html#method-i-to_s">#to_s — ResourceNotFound</a>
|
168
|
+
|
169
|
+
<li class="method"><a href="APIError.html#method-i-to_s">#to_s — APIError</a>
|
170
|
+
|
171
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-users_events">#users_events — Songkickr::Remote</a>
|
172
|
+
|
173
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-users_tracked_artists">#users_tracked_artists — Songkickr::Remote</a>
|
174
|
+
|
175
|
+
<li class="method"><a href="Songkickr/Remote.html#method-i-venue">#venue — Songkickr::Remote</a>
|
176
|
+
|
177
|
+
</ul>
|
178
|
+
|
179
|
+
|
180
|
+
<footer id="validator-badges">
|
181
|
+
<p><a href="http://validator.w3.org/check/referer">[Validate]</a>
|
182
|
+
<p>Generated by <a href="https://github.com/rdoc/rdoc">RDoc</a> 3.12.
|
183
|
+
<p>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish Rdoc Generator</a> 3.
|
184
|
+
</footer>
|
185
|
+
|
data/lib/songkickr/artist.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
module Songkickr
|
2
2
|
# A single artist
|
3
3
|
#
|
4
|
-
# {
|
4
|
+
# {
|
5
5
|
# "uri":"http://www.songkick.com/artists/253846-radiohead",
|
6
6
|
# "displayName":"Radiohead",
|
7
7
|
# "id":253846,
|
@@ -10,8 +10,8 @@ module Songkickr
|
|
10
10
|
#
|
11
11
|
# http://www.songkick.com/developer/artist-search
|
12
12
|
class Artist
|
13
|
-
attr_accessor :uri, :display_name, :id, :
|
14
|
-
|
13
|
+
attr_accessor :uri, :display_name, :id, :on_tour_until
|
14
|
+
|
15
15
|
# Accepts a hash of artist attributes.
|
16
16
|
def initialize(artist_hash = {})
|
17
17
|
@uri = artist_hash["uri"]
|
data/lib/songkickr/remote.rb
CHANGED
@@ -36,7 +36,7 @@ module Songkickr
|
|
36
36
|
# * +location+ - See the Songkick website for instructions on how to use the location parameter http://www.songkick.com/developer/location-search
|
37
37
|
def events(query = {})
|
38
38
|
path = extract_path_from_query(query)
|
39
|
-
result =
|
39
|
+
result = get("#{path}/events.json", :query => query)
|
40
40
|
Songkickr::EventResult.new result
|
41
41
|
end
|
42
42
|
|
@@ -48,9 +48,7 @@ module Songkickr
|
|
48
48
|
# === Parameters
|
49
49
|
# * +event_id+ - Songkick event ID. Extract the event ID either from a previous API call or from the URL of the event page on the website.
|
50
50
|
def event(event_id)
|
51
|
-
result =
|
52
|
-
# and now for some dirrty hack
|
53
|
-
raise ResouceNotFound if result['resultsPage']['error']
|
51
|
+
result = get("/events/#{event_id}.json")
|
54
52
|
Songkickr::Event.new result["resultsPage"]["results"]["event"]
|
55
53
|
end
|
56
54
|
|
@@ -67,7 +65,7 @@ module Songkickr
|
|
67
65
|
# * +per_page+ - Number of items on a page
|
68
66
|
# * +page+ - Number of page
|
69
67
|
def gigography(artist_id, query= {})
|
70
|
-
result =
|
68
|
+
result = get("/artists/#{artist_id}/gigography.json",:query=>query)
|
71
69
|
Songkickr::EventResult.new result
|
72
70
|
end
|
73
71
|
|
@@ -82,7 +80,7 @@ module Songkickr
|
|
82
80
|
# ==== Query Parameters
|
83
81
|
# * +artist_name+ - Name of an artist. <em>Ex. 'Lady Gaga', 'Slayer', 'Atmosphere'</em>
|
84
82
|
def artist_search(query={})
|
85
|
-
result =
|
83
|
+
result = get("/search/artists.json", :query => query)
|
86
84
|
Songkickr::ArtistResult.new result
|
87
85
|
end
|
88
86
|
|
@@ -99,7 +97,7 @@ module Songkickr
|
|
99
97
|
# * +page+ - Page number
|
100
98
|
# * +per_page+ - Number of results per page, max 50.
|
101
99
|
def artist_events(artist_id, query = {})
|
102
|
-
result =
|
100
|
+
result = get("/artists/#{artist_id}/calendar.json", :query => query)
|
103
101
|
Songkickr::EventResult.new result
|
104
102
|
end
|
105
103
|
|
@@ -121,10 +119,25 @@ module Songkickr
|
|
121
119
|
# * +max_date+ - Most recent date for which you want to look for events
|
122
120
|
# * +location+ - see the Songkick website for instructions on how to use the location parameter
|
123
121
|
def users_events(username, query = {})
|
124
|
-
result =
|
122
|
+
result = get("/users/#{username}/events.json", :query => query)
|
125
123
|
Songkickr::EventResult.new result
|
126
124
|
end
|
127
125
|
|
126
|
+
# ==== User Tracked Artists
|
127
|
+
# http://www.songkick.com/developer/trackings
|
128
|
+
#
|
129
|
+
# === Parameters
|
130
|
+
# * +username+ - A Songkick username.
|
131
|
+
# * +query+ - A hash of query parameters, see below for options.
|
132
|
+
#
|
133
|
+
# ==== Query Parameters
|
134
|
+
# * +page+ - Page number
|
135
|
+
# * +per_page+ - Number of results per page, max 50.
|
136
|
+
def users_tracked_artists(username, query = {})
|
137
|
+
result = get("/users/#{username}/artists/tracked.json", :query => query)
|
138
|
+
Songkickr::ArtistResult.new result
|
139
|
+
end
|
140
|
+
|
128
141
|
# ==== Metro Area Events (Upcoming)
|
129
142
|
# Returns an array of Events.
|
130
143
|
#
|
@@ -138,7 +151,7 @@ module Songkickr
|
|
138
151
|
# * +page+ - Page number
|
139
152
|
# * +per_page+ - Number of results per page, max 50.
|
140
153
|
def metro_areas_events(metro_area_id, query = {})
|
141
|
-
result =
|
154
|
+
result = get("/metro_areas/#{metro_area_id}/calendar.json", :query => query)
|
142
155
|
Songkickr::EventResult.new result
|
143
156
|
end
|
144
157
|
|
@@ -149,7 +162,7 @@ module Songkickr
|
|
149
162
|
#
|
150
163
|
# * +event_id+ - Songkick event ID. Extract the event ID either from a previous API call or from the URL of the event page on the website.
|
151
164
|
def concert_setlists(event_id)
|
152
|
-
result =
|
165
|
+
result = get("/events/#{event_id}/setlists.json")
|
153
166
|
Songkickr::ConcertSetlistResult.new result
|
154
167
|
end
|
155
168
|
|
@@ -162,7 +175,7 @@ module Songkickr
|
|
162
175
|
# ==== Query Parameters
|
163
176
|
# * +location+ - 'geo:{lat,lng}' string <em>Ex. 'geo:{-0.128,51.5078}'</em>
|
164
177
|
def location_search(query = {})
|
165
|
-
result =
|
178
|
+
result = get("/search/locations.json", :query => query)
|
166
179
|
Songkickr::LocationResult.new result
|
167
180
|
end
|
168
181
|
|
@@ -173,11 +186,21 @@ module Songkickr
|
|
173
186
|
#
|
174
187
|
# * +venue_id+ - Songkick venue ID.
|
175
188
|
def venue(venue_id)
|
176
|
-
result =
|
177
|
-
raise ResouceNotFound if result['resultsPage']['error']
|
189
|
+
result = get("/venues/#{venue_id}.json")
|
178
190
|
Songkickr::Venue.new result['resultsPage']['results']['venue']
|
179
191
|
end
|
180
192
|
|
193
|
+
def get(location, query_params = {})
|
194
|
+
result = self.class.get(location, query_params)
|
195
|
+
# FIXME: this is shit. should be based on on http response.
|
196
|
+
if result['resultsPage']['error']
|
197
|
+
msg = result['resultsPage']['error']['message']
|
198
|
+
raise ResourceNotFound if msg =~ /not found/
|
199
|
+
raise APIError.new(msg)
|
200
|
+
end
|
201
|
+
result
|
202
|
+
end
|
203
|
+
|
181
204
|
|
182
205
|
private
|
183
206
|
|
data/lib/songkickr.rb
CHANGED
@@ -23,17 +23,31 @@ class APIKeyNotSet < StandardError;
|
|
23
23
|
end
|
24
24
|
end
|
25
25
|
|
26
|
-
class
|
26
|
+
class APIError < StandardError;
|
27
|
+
|
28
|
+
def initialize(message = "API Error")
|
29
|
+
@message = message
|
30
|
+
end
|
31
|
+
|
32
|
+
def to_s
|
33
|
+
@message
|
34
|
+
end
|
35
|
+
end
|
36
|
+
|
37
|
+
class ResourceNotFound < APIError;
|
27
38
|
def to_s
|
28
39
|
"Resource not found"
|
29
40
|
end
|
30
41
|
end
|
31
42
|
|
43
|
+
|
44
|
+
|
45
|
+
|
32
46
|
module Songkickr
|
33
47
|
# Returns the Songkick API key
|
34
48
|
# In order to use the Songkick API, you must have a Songkick API (their rule, not mine).
|
35
49
|
# Get an API key for your app from http://developer.songkick.com/
|
36
|
-
#
|
50
|
+
#
|
37
51
|
# ==== Example
|
38
52
|
#
|
39
53
|
# require 'songkickr'
|
data/songkickr.gemspec
CHANGED
@@ -5,13 +5,14 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "songkickr"
|
8
|
-
s.version = "0.
|
8
|
+
s.version = "0.3.0"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Jared Mehle"]
|
12
|
-
s.date = "2012-
|
12
|
+
s.date = "2012-09-29"
|
13
13
|
s.description = "A Ruby wrapper around the Songkick API. Visit www.songkick.com/developer for documentation on the Songkick API. "
|
14
14
|
s.email = "jrmehle@gmail.com"
|
15
|
+
s.executables = ["autospec", "convert_to_should_syntax", "guard", "htmldiff", "httparty", "jeweler", "ldiff", "rake", "rake2thor", "rg", "ri", "rspec", "thor"]
|
15
16
|
s.extra_rdoc_files = [
|
16
17
|
"LICENSE",
|
17
18
|
"README.rdoc"
|
@@ -24,9 +25,24 @@ Gem::Specification.new do |s|
|
|
24
25
|
"README.rdoc",
|
25
26
|
"Rakefile",
|
26
27
|
"VERSION",
|
28
|
+
"bin/autospec",
|
29
|
+
"bin/convert_to_should_syntax",
|
30
|
+
"bin/guard",
|
31
|
+
"bin/htmldiff",
|
32
|
+
"bin/httparty",
|
33
|
+
"bin/jeweler",
|
34
|
+
"bin/ldiff",
|
35
|
+
"bin/rake",
|
36
|
+
"bin/rake2thor",
|
37
|
+
"bin/rg",
|
38
|
+
"bin/ri",
|
39
|
+
"bin/rspec",
|
40
|
+
"bin/thor",
|
41
|
+
"doc/APIError.html",
|
27
42
|
"doc/APIKeyNotSet.html",
|
28
43
|
"doc/LICENSE.html",
|
29
44
|
"doc/README_rdoc.html",
|
45
|
+
"doc/ResourceNotFound.html",
|
30
46
|
"doc/Songkickr.html",
|
31
47
|
"doc/Songkickr/Artist.html",
|
32
48
|
"doc/Songkickr/ArtistResult.html",
|
@@ -41,6 +57,7 @@ Gem::Specification.new do |s|
|
|
41
57
|
"doc/Songkickr/SetlistItem.html",
|
42
58
|
"doc/Songkickr/Venue.html",
|
43
59
|
"doc/created.rid",
|
60
|
+
"doc/images/add.png",
|
44
61
|
"doc/images/brick.png",
|
45
62
|
"doc/images/brick_link.png",
|
46
63
|
"doc/images/bug.png",
|
@@ -48,6 +65,7 @@ Gem::Specification.new do |s|
|
|
48
65
|
"doc/images/bullet_toggle_minus.png",
|
49
66
|
"doc/images/bullet_toggle_plus.png",
|
50
67
|
"doc/images/date.png",
|
68
|
+
"doc/images/delete.png",
|
51
69
|
"doc/images/find.png",
|
52
70
|
"doc/images/loadingAnimation.gif",
|
53
71
|
"doc/images/macFFBgHack.png",
|
@@ -57,14 +75,20 @@ Gem::Specification.new do |s|
|
|
57
75
|
"doc/images/page_white_width.png",
|
58
76
|
"doc/images/plugin.png",
|
59
77
|
"doc/images/ruby.png",
|
78
|
+
"doc/images/tag_blue.png",
|
60
79
|
"doc/images/tag_green.png",
|
80
|
+
"doc/images/transparent.png",
|
61
81
|
"doc/images/wrench.png",
|
62
82
|
"doc/images/wrench_orange.png",
|
63
83
|
"doc/images/zoom.png",
|
64
84
|
"doc/index.html",
|
65
85
|
"doc/js/darkfish.js",
|
66
86
|
"doc/js/jquery.js",
|
87
|
+
"doc/js/navigation.js",
|
67
88
|
"doc/js/quicksearch.js",
|
89
|
+
"doc/js/search.js",
|
90
|
+
"doc/js/search_index.js",
|
91
|
+
"doc/js/searcher.js",
|
68
92
|
"doc/js/thickbox-compressed.js",
|
69
93
|
"doc/lib/songkickr/artist_rb.html",
|
70
94
|
"doc/lib/songkickr/artist_result_rb.html",
|
@@ -80,6 +104,7 @@ Gem::Specification.new do |s|
|
|
80
104
|
"doc/lib/songkickr/venue_rb.html",
|
81
105
|
"doc/lib/songkickr_rb.html",
|
82
106
|
"doc/rdoc.css",
|
107
|
+
"doc/table_of_contents.html",
|
83
108
|
"lib/songkickr.rb",
|
84
109
|
"lib/songkickr/artist.rb",
|
85
110
|
"lib/songkickr/artist_result.rb",
|
@@ -101,6 +126,13 @@ Gem::Specification.new do |s|
|
|
101
126
|
"test/fixtures/locations_bar.json",
|
102
127
|
"test/fixtures/no_events.json",
|
103
128
|
"test/fixtures/resource_not_found.json",
|
129
|
+
"test/fixtures/vcr/invalid_api_key.yml",
|
130
|
+
"test/fixtures/vcr/invalid_event_id.yml",
|
131
|
+
"test/fixtures/vcr/invalid_user.yml",
|
132
|
+
"test/fixtures/vcr/invalid_venue_id.yml",
|
133
|
+
"test/fixtures/vcr/valid_event.yml",
|
134
|
+
"test/fixtures/vcr/valid_user.yml",
|
135
|
+
"test/fixtures/vcr/valid_venue.yml",
|
104
136
|
"test/fixtures/venue_1276231.json",
|
105
137
|
"test/helper.rb",
|
106
138
|
"test/songkickr/test_artist.rb",
|
@@ -108,11 +140,12 @@ Gem::Specification.new do |s|
|
|
108
140
|
"test/songkickr/test_location.rb",
|
109
141
|
"test/songkickr/test_remote.rb",
|
110
142
|
"test/songkickr/test_venue.rb",
|
111
|
-
"test/test_songkickr.rb"
|
143
|
+
"test/test_songkickr.rb",
|
144
|
+
"test/vcr_helper.rb"
|
112
145
|
]
|
113
146
|
s.homepage = "http://github.com/jrmehle/songkickr"
|
114
147
|
s.require_paths = ["lib"]
|
115
|
-
s.rubygems_version = "1.8.
|
148
|
+
s.rubygems_version = "1.8.24"
|
116
149
|
s.summary = "A Ruby wrapper around the Songkick API."
|
117
150
|
|
118
151
|
if s.respond_to? :specification_version then
|
@@ -137,6 +170,34 @@ Gem::Specification.new do |s|
|
|
137
170
|
s.add_development_dependency(%q<shoulda>, [">= 2.11.0"])
|
138
171
|
s.add_development_dependency(%q<fakeweb>, [">= 1.3.0"])
|
139
172
|
s.add_development_dependency(%q<redgreen>, [">= 1.2.2"])
|
173
|
+
s.add_development_dependency(%q<redgreen>, [">= 1.2.2"])
|
174
|
+
s.add_development_dependency(%q<crack>, [">= 0"])
|
175
|
+
s.add_development_dependency(%q<httparty>, [">= 0"])
|
176
|
+
s.add_development_dependency(%q<test-unit>, [">= 0"])
|
177
|
+
s.add_development_dependency(%q<rake>, [">= 0"])
|
178
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
179
|
+
s.add_development_dependency(%q<vcr>, [">= 0"])
|
180
|
+
s.add_development_dependency(%q<shoulda>, [">= 2.11.0"])
|
181
|
+
s.add_development_dependency(%q<fakeweb>, [">= 1.3.0"])
|
182
|
+
s.add_development_dependency(%q<redgreen>, [">= 1.2.2"])
|
183
|
+
s.add_development_dependency(%q<crack>, [">= 0"])
|
184
|
+
s.add_development_dependency(%q<httparty>, [">= 0"])
|
185
|
+
s.add_development_dependency(%q<test-unit>, [">= 0"])
|
186
|
+
s.add_development_dependency(%q<rake>, [">= 0"])
|
187
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
188
|
+
s.add_development_dependency(%q<vcr>, [">= 0"])
|
189
|
+
s.add_development_dependency(%q<shoulda>, [">= 2.11.0"])
|
190
|
+
s.add_development_dependency(%q<fakeweb>, [">= 1.3.0"])
|
191
|
+
s.add_development_dependency(%q<redgreen>, [">= 1.2.2"])
|
192
|
+
s.add_development_dependency(%q<crack>, [">= 0"])
|
193
|
+
s.add_development_dependency(%q<httparty>, [">= 0"])
|
194
|
+
s.add_development_dependency(%q<test-unit>, [">= 0"])
|
195
|
+
s.add_development_dependency(%q<rake>, [">= 0"])
|
196
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
197
|
+
s.add_development_dependency(%q<vcr>, [">= 0"])
|
198
|
+
s.add_development_dependency(%q<shoulda>, [">= 2.11.0"])
|
199
|
+
s.add_development_dependency(%q<fakeweb>, [">= 1.3.0"])
|
200
|
+
s.add_development_dependency(%q<redgreen>, [">= 1.2.2"])
|
140
201
|
else
|
141
202
|
s.add_dependency(%q<songkickr>, [">= 0"])
|
142
203
|
s.add_dependency(%q<shoulda>, [">= 2.11.0"])
|
@@ -156,6 +217,34 @@ Gem::Specification.new do |s|
|
|
156
217
|
s.add_dependency(%q<shoulda>, [">= 2.11.0"])
|
157
218
|
s.add_dependency(%q<fakeweb>, [">= 1.3.0"])
|
158
219
|
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
220
|
+
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
221
|
+
s.add_dependency(%q<crack>, [">= 0"])
|
222
|
+
s.add_dependency(%q<httparty>, [">= 0"])
|
223
|
+
s.add_dependency(%q<test-unit>, [">= 0"])
|
224
|
+
s.add_dependency(%q<rake>, [">= 0"])
|
225
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
226
|
+
s.add_dependency(%q<vcr>, [">= 0"])
|
227
|
+
s.add_dependency(%q<shoulda>, [">= 2.11.0"])
|
228
|
+
s.add_dependency(%q<fakeweb>, [">= 1.3.0"])
|
229
|
+
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
230
|
+
s.add_dependency(%q<crack>, [">= 0"])
|
231
|
+
s.add_dependency(%q<httparty>, [">= 0"])
|
232
|
+
s.add_dependency(%q<test-unit>, [">= 0"])
|
233
|
+
s.add_dependency(%q<rake>, [">= 0"])
|
234
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
235
|
+
s.add_dependency(%q<vcr>, [">= 0"])
|
236
|
+
s.add_dependency(%q<shoulda>, [">= 2.11.0"])
|
237
|
+
s.add_dependency(%q<fakeweb>, [">= 1.3.0"])
|
238
|
+
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
239
|
+
s.add_dependency(%q<crack>, [">= 0"])
|
240
|
+
s.add_dependency(%q<httparty>, [">= 0"])
|
241
|
+
s.add_dependency(%q<test-unit>, [">= 0"])
|
242
|
+
s.add_dependency(%q<rake>, [">= 0"])
|
243
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
244
|
+
s.add_dependency(%q<vcr>, [">= 0"])
|
245
|
+
s.add_dependency(%q<shoulda>, [">= 2.11.0"])
|
246
|
+
s.add_dependency(%q<fakeweb>, [">= 1.3.0"])
|
247
|
+
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
159
248
|
end
|
160
249
|
else
|
161
250
|
s.add_dependency(%q<songkickr>, [">= 0"])
|
@@ -176,6 +265,34 @@ Gem::Specification.new do |s|
|
|
176
265
|
s.add_dependency(%q<shoulda>, [">= 2.11.0"])
|
177
266
|
s.add_dependency(%q<fakeweb>, [">= 1.3.0"])
|
178
267
|
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
268
|
+
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
269
|
+
s.add_dependency(%q<crack>, [">= 0"])
|
270
|
+
s.add_dependency(%q<httparty>, [">= 0"])
|
271
|
+
s.add_dependency(%q<test-unit>, [">= 0"])
|
272
|
+
s.add_dependency(%q<rake>, [">= 0"])
|
273
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
274
|
+
s.add_dependency(%q<vcr>, [">= 0"])
|
275
|
+
s.add_dependency(%q<shoulda>, [">= 2.11.0"])
|
276
|
+
s.add_dependency(%q<fakeweb>, [">= 1.3.0"])
|
277
|
+
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
278
|
+
s.add_dependency(%q<crack>, [">= 0"])
|
279
|
+
s.add_dependency(%q<httparty>, [">= 0"])
|
280
|
+
s.add_dependency(%q<test-unit>, [">= 0"])
|
281
|
+
s.add_dependency(%q<rake>, [">= 0"])
|
282
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
283
|
+
s.add_dependency(%q<vcr>, [">= 0"])
|
284
|
+
s.add_dependency(%q<shoulda>, [">= 2.11.0"])
|
285
|
+
s.add_dependency(%q<fakeweb>, [">= 1.3.0"])
|
286
|
+
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
287
|
+
s.add_dependency(%q<crack>, [">= 0"])
|
288
|
+
s.add_dependency(%q<httparty>, [">= 0"])
|
289
|
+
s.add_dependency(%q<test-unit>, [">= 0"])
|
290
|
+
s.add_dependency(%q<rake>, [">= 0"])
|
291
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
292
|
+
s.add_dependency(%q<vcr>, [">= 0"])
|
293
|
+
s.add_dependency(%q<shoulda>, [">= 2.11.0"])
|
294
|
+
s.add_dependency(%q<fakeweb>, [">= 1.3.0"])
|
295
|
+
s.add_dependency(%q<redgreen>, [">= 1.2.2"])
|
179
296
|
end
|
180
297
|
end
|
181
298
|
|
@@ -0,0 +1,63 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: http://api.songkick.com/api/3.0/events/123.json?apikey=omgwtfbbq_fake_key
|
6
|
+
body:
|
7
|
+
encoding: US-ASCII
|
8
|
+
string: ''
|
9
|
+
headers: {}
|
10
|
+
response:
|
11
|
+
status:
|
12
|
+
code: 403
|
13
|
+
message: Forbidden
|
14
|
+
headers:
|
15
|
+
date:
|
16
|
+
- Mon, 20 Aug 2012 17:27:42 GMT
|
17
|
+
server:
|
18
|
+
- thin 1.2.4 codename Flaming Astroboy
|
19
|
+
content-type:
|
20
|
+
- application/json
|
21
|
+
vary:
|
22
|
+
- Accept-Encoding
|
23
|
+
connection:
|
24
|
+
- close
|
25
|
+
transfer-encoding:
|
26
|
+
- chunked
|
27
|
+
body:
|
28
|
+
encoding: US-ASCII
|
29
|
+
string: ! '{"resultsPage":{"status":"error","error":{"message":"Invalid or missing
|
30
|
+
apikey"}}}'
|
31
|
+
http_version: '1.1'
|
32
|
+
recorded_at: Mon, 20 Aug 2012 17:27:42 GMT
|
33
|
+
- request:
|
34
|
+
method: get
|
35
|
+
uri: http://api.songkick.com/api/3.0/events/17522.json?apikey=omgwtfbbq_fake_key
|
36
|
+
body:
|
37
|
+
encoding: US-ASCII
|
38
|
+
string: ''
|
39
|
+
headers: {}
|
40
|
+
response:
|
41
|
+
status:
|
42
|
+
code: 403
|
43
|
+
message: Forbidden
|
44
|
+
headers:
|
45
|
+
date:
|
46
|
+
- Mon, 20 Aug 2012 17:39:30 GMT
|
47
|
+
server:
|
48
|
+
- thin 1.2.4 codename Flaming Astroboy
|
49
|
+
content-type:
|
50
|
+
- application/json
|
51
|
+
vary:
|
52
|
+
- Accept-Encoding
|
53
|
+
connection:
|
54
|
+
- close
|
55
|
+
transfer-encoding:
|
56
|
+
- chunked
|
57
|
+
body:
|
58
|
+
encoding: US-ASCII
|
59
|
+
string: ! '{"resultsPage":{"status":"error","error":{"message":"Invalid or missing
|
60
|
+
apikey"}}}'
|
61
|
+
http_version: '1.1'
|
62
|
+
recorded_at: Mon, 20 Aug 2012 17:39:30 GMT
|
63
|
+
recorded_with: VCR 2.2.4
|