Fixed #18: added v1 namespace under API

This commit is contained in:
Eliot Berriot 2017-06-26 20:19:09 +02:00
parent 3c2a6914ce
commit 70634048c6
12 changed files with 44 additions and 40 deletions

View file

@ -13,7 +13,7 @@ class TestAPI(TestCase):
return_value=api_data.recordings['search']['brontide matador'])
def test_can_search_recording_in_musicbrainz_api(self, *mocks):
query = 'brontide matador'
url = reverse('api:providers:musicbrainz:search-recordings')
url = reverse('api:v1:providers:musicbrainz:search-recordings')
expected = api_data.recordings['search']['brontide matador']
response = self.client.get(url, data={'query': query})
@ -24,7 +24,7 @@ class TestAPI(TestCase):
return_value=api_data.releases['search']['brontide matador'])
def test_can_search_release_in_musicbrainz_api(self, *mocks):
query = 'brontide matador'
url = reverse('api:providers:musicbrainz:search-releases')
url = reverse('api:v1:providers:musicbrainz:search-releases')
expected = api_data.releases['search']['brontide matador']
response = self.client.get(url, data={'query': query})
@ -35,7 +35,7 @@ class TestAPI(TestCase):
return_value=api_data.artists['search']['lost fingers'])
def test_can_search_artists_in_musicbrainz_api(self, *mocks):
query = 'lost fingers'
url = reverse('api:providers:musicbrainz:search-artists')
url = reverse('api:v1:providers:musicbrainz:search-artists')
expected = api_data.artists['search']['lost fingers']
response = self.client.get(url, data={'query': query})
@ -46,7 +46,7 @@ class TestAPI(TestCase):
return_value=api_data.artists['get']['lost fingers'])
def test_can_get_artist_in_musicbrainz_api(self, *mocks):
uuid = 'ac16bbc0-aded-4477-a3c3-1d81693d58c9'
url = reverse('api:providers:musicbrainz:artist-detail', kwargs={
url = reverse('api:v1:providers:musicbrainz:artist-detail', kwargs={
'uuid': uuid,
})
response = self.client.get(url)
@ -60,7 +60,7 @@ class TestAPI(TestCase):
def test_can_broswe_release_group_using_musicbrainz_api(self, *mocks):
uuid = 'ac16bbc0-aded-4477-a3c3-1d81693d58c9'
url = reverse(
'api:providers:musicbrainz:release-group-browse',
'api:v1:providers:musicbrainz:release-group-browse',
kwargs={
'artist_uuid': uuid,
}
@ -76,7 +76,7 @@ class TestAPI(TestCase):
def test_can_broswe_releases_using_musicbrainz_api(self, *mocks):
uuid = 'f04ed607-11b7-3843-957e-503ecdd485d1'
url = reverse(
'api:providers:musicbrainz:release-browse',
'api:v1:providers:musicbrainz:release-browse',
kwargs={
'release_group_uuid': uuid,
}