mirror of
https://github.com/c0de-archive/spotipy.git
synced 2024-11-04 23:17:48 +00:00
Fixed album search test
This commit is contained in:
parent
9b5b65073c
commit
ceaa030468
@ -1,2 +1,3 @@
|
||||
v<version>, <date> -- Initial release.
|
||||
v1.40, June 12, 2014 -- Initial public release.
|
||||
v1.42, June 19, 2014 -- Removed dependency on simplejson
|
||||
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
import sys
|
||||
import spotipy
|
||||
|
||||
|
4
setup.py
4
setup.py
@ -3,11 +3,11 @@ from setuptools import setup
|
||||
|
||||
setup(
|
||||
name='SpotipyWebApi',
|
||||
version='1.41',
|
||||
version='1.42',
|
||||
description='simple client for the Spotify Web API',
|
||||
author="@plamere",
|
||||
author_email="paul@echonest.com",
|
||||
url='http://github.com/plamere/spotipy',
|
||||
install_requires=['requests>=1.0', 'simplejson>=3.5.2'],
|
||||
install_requires=['requests>=1.0'],
|
||||
license='LICENSE.txt',
|
||||
py_modules=['spotipy', 'spotipy.oauth2'],)
|
||||
|
@ -4,7 +4,7 @@ from __future__ import print_function
|
||||
|
||||
import base64
|
||||
import requests
|
||||
import simplejson as json
|
||||
import json
|
||||
|
||||
|
||||
__all__ = ['oauth2']
|
||||
|
@ -2,7 +2,7 @@ import base64
|
||||
import urllib
|
||||
import requests
|
||||
import os
|
||||
import simplejson as json
|
||||
import json
|
||||
import time
|
||||
|
||||
class SpotifyOauthError(Exception):
|
||||
|
@ -86,7 +86,7 @@ class TestSpotipy(unittest.TestCase):
|
||||
results = self.spotify.search(q='weezer pinkerton', type='album')
|
||||
self.assertTrue('albums' in results)
|
||||
self.assertTrue(len(results['albums']['items']) > 0)
|
||||
self.assertTrue(results['albums']['items'][0]['name'] == 'Pinkerton')
|
||||
self.assertTrue(results['albums']['items'][0]['name'].find('Pinkerton') >= 0)
|
||||
|
||||
def test_track_search(self):
|
||||
results = self.spotify.search(q='el scorcho weezer', type='track')
|
||||
|
Loading…
Reference in New Issue
Block a user