From 7b60e65ea4f82c170544f7ef4584cc160a56e5fe Mon Sep 17 00:00:00 2001 From: jcbirdwell Date: Thu, 28 Dec 2023 17:58:39 -0600 Subject: [PATCH] test_get_album_browse_id: hindsight test edit and bulletproof fix for warning --- tests/test.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test.py b/tests/test.py index fab1746..85c9186 100644 --- a/tests/test.py +++ b/tests/test.py @@ -235,13 +235,13 @@ class TestYTMusic(unittest.TestCase): self.assertGreater(len(results), 100) def test_get_album_browse_id(self): + warnings.filterwarnings(action="ignore", category=DeprecationWarning) browse_id = self.yt.get_album_browse_id("OLAK5uy_nMr9h2VlS-2PULNz3M3XVXQj_P3C2bqaY") self.assertEqual(browse_id, sample_album) with self.subTest(): escaped_browse_id = self.yt.get_album_browse_id( "OLAK5uy_nbMYyrfeg5ZgknoOsOGBL268hGxtcbnDM") - # general length, I believe 17 is standard, but unsure if edge cases exist - self.assertLess(len(escaped_browse_id), 24) + self.assertEqual(escaped_browse_id, 'MPREb_scJdtUCpPE2') def test_get_album(self): results = self.yt_auth.get_album(sample_album)