feature: add_history_item (closes #295) (OzymandiasTheGreat/mopidy-ytmusic/issues/58)

This commit is contained in:
sigma67 2022-12-07 18:07:47 +01:00
commit d0ec2bbf72
No known key found for this signature in database
GPG key ID: 1C314227DF0103D0
6 changed files with 30 additions and 12 deletions

View file

@ -277,11 +277,13 @@ class TestYTMusic(unittest.TestCase):
songs = self.yt_auth.get_history()
self.assertGreater(len(songs), 0)
@unittest.skip
def test_remove_history_items(self):
def test_manipulate_history_items(self):
song = self.yt_auth.get_song(sample_video)
response = self.yt_auth.add_history_item(song)
self.assertEqual(response.status_code, 204)
songs = self.yt_auth.get_history()
response = self.yt_auth.remove_history_items(
[songs[0]['feedbackToken'], songs[1]['feedbackToken']])
self.assertGreater(len(songs), 0)
response = self.yt_auth.remove_history_items([songs[0]['feedbackToken']])
self.assertIn('feedbackResponses', response)
def test_rate_song(self):