scrobbler-ng 2.0.9 → 2.0.10

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.
data/VERSION.yml CHANGED
@@ -1,5 +1,5 @@
1
1
  ---
2
- :patch: 9
3
2
  :major: 2
4
- :build:
5
3
  :minor: 0
4
+ :patch: 10
5
+ :build:
@@ -10,7 +10,7 @@ module Scrobbler
10
10
  include Scrobbler::StreamableObjectFuncs
11
11
 
12
12
  attr_reader :name, :mbid, :playcount, :rank, :url, :count, :listeners
13
- attr_reader :chartposition, :streamable, :match, :tagcount
13
+ attr_reader :chartposition, :streamable, :match, :tagcount, :bio
14
14
 
15
15
  # Alias for Artist.new(:xml => xml)
16
16
  #
@@ -58,6 +58,7 @@ module Scrobbler
58
58
  child.children.each do |childL2|
59
59
  @listeners = childL2.content.to_i if childL2.name == 'listeners'
60
60
  @playcount = childL2.content.to_i if childL2.name == 'playcount'
61
+ @playcount = childL2.content.to_i if childL2.name == 'plays'
61
62
  end
62
63
  when 'similar'
63
64
  # Ignore them for the moment, they are not stored.
@@ -65,6 +66,9 @@ module Scrobbler
65
66
  child.children.each do |childL2|
66
67
  @bio = childL2.content if childL2.name == 'content'
67
68
  end
69
+ when 'tags'
70
+ # Ignore them at the moment, inlude them later
71
+ # TODO Include a interface for these tags
68
72
  when 'text'
69
73
  # ignore, these are only blanks
70
74
  when '#text'
data/scrobbler-ng.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{scrobbler-ng}
8
- s.version = "2.0.9"
8
+ s.version = "2.0.10"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["John Nunemaker", "Jonathan Rudenberg", "Uwe L. Korn"]
12
- s.date = %q{2010-09-18}
12
+ s.date = %q{2010-09-25}
13
13
  s.description = %q{A ruby library for accessing the Last.fm 2.0 API. It is higly optimized so that it uses less memory and parses XML (through Nokogiri) than other implementations.}
14
14
  s.email = %q{uwelk@xhochy.org}
15
15
  s.extra_rdoc_files = [
@@ -58,30 +58,30 @@ Gem::Specification.new do |s|
58
58
  s.rubygems_version = %q{1.3.7}
59
59
  s.summary = %q{A ruby library for accessing the last.fm v2 webservices}
60
60
  s.test_files = [
61
- "test/spec_helper.rb",
62
- "test/unit/user_spec.rb",
61
+ "test/unit/tag_spec.rb",
62
+ "test/unit/playlist_spec.rb",
63
+ "test/unit/album_spec.rb",
63
64
  "test/unit/radio_spec.rb",
64
- "test/unit/tag_spec.rb",
65
- "test/unit/geo_spec.rb",
65
+ "test/unit/event_spec.rb",
66
66
  "test/unit/venue_spec.rb",
67
- "test/unit/simpleauth_test.rb",
68
- "test/unit/playlist_spec.rb",
69
- "test/unit/track_spec.rb",
67
+ "test/unit/user_spec.rb",
70
68
  "test/unit/artist_spec.rb",
71
- "test/unit/event_spec.rb",
72
- "test/unit/album_spec.rb",
73
- "test/unit/authentication_spec.rb",
74
69
  "test/unit/playing_test.rb",
70
+ "test/unit/simpleauth_test.rb",
71
+ "test/unit/geo_spec.rb",
75
72
  "test/unit/library_spec.rb",
76
- "test/mocks/rest.rb",
77
- "test/mocks/library.rb",
73
+ "test/unit/track_spec.rb",
74
+ "test/unit/authentication_spec.rb",
75
+ "test/spec_helper.rb",
78
76
  "test/test_helper.rb",
79
- "examples/track.rb",
80
- "examples/album.rb",
81
- "examples/artist.rb",
77
+ "test/mocks/library.rb",
78
+ "test/mocks/rest.rb",
82
79
  "examples/tag.rb",
80
+ "examples/track.rb",
83
81
  "examples/user.rb",
84
- "examples/scrobble.rb"
82
+ "examples/artist.rb",
83
+ "examples/scrobble.rb",
84
+ "examples/album.rb"
85
85
  ]
86
86
 
87
87
  if s.respond_to? :specification_version then
@@ -7,7 +7,7 @@
7
7
  }.each do |url, file|
8
8
  register_fw('method=library.getartists&' + url, 'library', file)
9
9
  end
10
- (2..7).each do |n|
10
+ (1..7).each do |n|
11
11
  register_fw('method=library.getartists&page=' + n.to_s +
12
12
  '&api_key=foo123&user=xhochy', 'library', "artists-p#{n}.xml")
13
13
  end
@@ -19,7 +19,7 @@ end
19
19
  }.each do |url, file|
20
20
  register_fw('method=library.gettracks&' + url, 'library', file)
21
21
  end
22
- (2..34).each do |n|
22
+ (1..34).each do |n|
23
23
  register_fw("user=xhochy&page=#{n}&api_key=foo123&method=library.gettracks",
24
24
  'library', "tracks-p#{n}.xml")
25
25
  end
@@ -27,7 +27,7 @@ end
27
27
  ## ## library.getalbums
28
28
  FakeWeb.register_uri(:get, WEB_BASE + 'limit=30&user=xhochy&api_key=foo123&method=library.getalbums', :body => File.join([FIXTURES_BASE, 'library', 'albums-f30.xml']))
29
29
  FakeWeb.register_uri(:get, WEB_BASE + 'user=xhochy&api_key=foo123&method=library.getalbums', :body => File.join([FIXTURES_BASE, 'library', 'albums-p1.xml']))
30
- (2..8).each do |n|
30
+ (1..8).each do |n|
31
31
  FakeWeb.register_uri(:get, WEB_BASE + 'method=library.getalbums&page=' +
32
32
  n.to_s + '&api_key=foo123&user=xhochy',
33
33
  :body => File.join([FIXTURES_BASE, 'library', 'albums-p' +
data/test/mocks/rest.rb CHANGED
@@ -105,6 +105,8 @@ register_fw('user=jnunemaker&api_key=foo123&method=user.getneighbours',
105
105
  'user', 'neighbours.xml')
106
106
  register_fw('user=jnunemaker&api_key=foo123&method=user.getfriends',
107
107
  'user', 'friends.xml')
108
+ register_fw('user=jnunemaker&api_key=foo123&method=user.getfriends&page=1',
109
+ 'user', 'friends.xml')
108
110
  register_fw('user=jnunemaker&api_key=foo123&method=user.getrecenttracks',
109
111
  'user', 'recenttracks.xml')
110
112
  register_fw('user=jnunemaker&api_key=foo123&method=user.getlovedtracks',
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scrobbler-ng
3
3
  version: !ruby/object:Gem::Version
4
- hash: 29
4
+ hash: 27
5
5
  prerelease: false
6
6
  segments:
7
7
  - 2
8
8
  - 0
9
- - 9
10
- version: 2.0.9
9
+ - 10
10
+ version: 2.0.10
11
11
  platform: ruby
12
12
  authors:
13
13
  - John Nunemaker
@@ -17,7 +17,7 @@ autorequire:
17
17
  bindir: bin
18
18
  cert_chain: []
19
19
 
20
- date: 2010-09-18 00:00:00 +02:00
20
+ date: 2010-09-25 00:00:00 +02:00
21
21
  default_executable:
22
22
  dependencies:
23
23
  - !ruby/object:Gem::Dependency
@@ -124,24 +124,24 @@ files:
124
124
  - tasks/rdoc.rake
125
125
  - tasks/tests.rake
126
126
  - tasks/yardoc.rake
127
- - test/spec_helper.rb
128
- - test/unit/user_spec.rb
129
- - test/unit/radio_spec.rb
130
127
  - test/unit/tag_spec.rb
131
- - test/unit/geo_spec.rb
132
- - test/unit/venue_spec.rb
133
- - test/unit/simpleauth_test.rb
134
128
  - test/unit/playlist_spec.rb
135
- - test/unit/track_spec.rb
136
- - test/unit/artist_spec.rb
137
- - test/unit/event_spec.rb
138
129
  - test/unit/album_spec.rb
139
- - test/unit/authentication_spec.rb
130
+ - test/unit/radio_spec.rb
131
+ - test/unit/event_spec.rb
132
+ - test/unit/venue_spec.rb
133
+ - test/unit/user_spec.rb
134
+ - test/unit/artist_spec.rb
140
135
  - test/unit/playing_test.rb
136
+ - test/unit/simpleauth_test.rb
137
+ - test/unit/geo_spec.rb
141
138
  - test/unit/library_spec.rb
142
- - test/mocks/rest.rb
143
- - test/mocks/library.rb
139
+ - test/unit/track_spec.rb
140
+ - test/unit/authentication_spec.rb
141
+ - test/spec_helper.rb
144
142
  - test/test_helper.rb
143
+ - test/mocks/library.rb
144
+ - test/mocks/rest.rb
145
145
  has_rdoc: true
146
146
  homepage: http://github.com/xhochy/scrobbler
147
147
  licenses: []
@@ -177,27 +177,27 @@ signing_key:
177
177
  specification_version: 3
178
178
  summary: A ruby library for accessing the last.fm v2 webservices
179
179
  test_files:
180
- - test/spec_helper.rb
181
- - test/unit/user_spec.rb
182
- - test/unit/radio_spec.rb
183
180
  - test/unit/tag_spec.rb
184
- - test/unit/geo_spec.rb
185
- - test/unit/venue_spec.rb
186
- - test/unit/simpleauth_test.rb
187
181
  - test/unit/playlist_spec.rb
188
- - test/unit/track_spec.rb
189
- - test/unit/artist_spec.rb
190
- - test/unit/event_spec.rb
191
182
  - test/unit/album_spec.rb
192
- - test/unit/authentication_spec.rb
183
+ - test/unit/radio_spec.rb
184
+ - test/unit/event_spec.rb
185
+ - test/unit/venue_spec.rb
186
+ - test/unit/user_spec.rb
187
+ - test/unit/artist_spec.rb
193
188
  - test/unit/playing_test.rb
189
+ - test/unit/simpleauth_test.rb
190
+ - test/unit/geo_spec.rb
194
191
  - test/unit/library_spec.rb
195
- - test/mocks/rest.rb
196
- - test/mocks/library.rb
192
+ - test/unit/track_spec.rb
193
+ - test/unit/authentication_spec.rb
194
+ - test/spec_helper.rb
197
195
  - test/test_helper.rb
198
- - examples/track.rb
199
- - examples/album.rb
200
- - examples/artist.rb
196
+ - test/mocks/library.rb
197
+ - test/mocks/rest.rb
201
198
  - examples/tag.rb
199
+ - examples/track.rb
202
200
  - examples/user.rb
201
+ - examples/artist.rb
203
202
  - examples/scrobble.rb
203
+ - examples/album.rb