Remove pyspotify test code

This commit is contained in:
Stein Magnus Jodal 2010-01-31 22:41:43 +01:00
parent 72a2215621
commit ff95f6e448

View File

@ -81,7 +81,6 @@ class LibspotifySessionManager(SpotifySessionManager, threading.Thread):
threading.Thread.__init__(self)
self.backend = backend
self.audio = AlsaController()
self.queued = False
def run(self):
self.connect()
@ -121,22 +120,3 @@ class LibspotifySessionManager(SpotifySessionManager, threading.Thread):
def end_of_track(self, session):
logger.debug('End of track')
def test(self):
# XXX This should play the first song in your first playlist :-)
playlist_no = 0
track_no = 0
try:
if not self.queued:
if len(self.playlists) > playlist_no:
playlist = self.playlists[playlist_no]
if playlist.is_loaded():
if playlist[track_no].is_loaded():
session.load(playlist[track_no])
session.play(1)
self.queued = True
logger.info('Playing "%s"',
playlist[track_no].name())
except Exception, e:
logger.exception(e)