diff --git a/lib/testing/song_test.py b/lib/testing/song_test.py index babeced17..b7edf6da5 100644 --- a/lib/testing/song_test.py +++ b/lib/testing/song_test.py @@ -27,6 +27,11 @@ def test_has_genres(self): assert("Rap" in Song.genres) assert("Pop" in Song.genres) assert("Rock" in Song.genres) + + + def test_unique_genres(self): + '''all song genres are unique.''' + assert len(Song.genres) == len(set(Song.genres)) def test_has_artists(self): '''keeps track of all Song artists.''' @@ -34,6 +39,10 @@ def test_has_artists(self): assert("Beyonce" in Song.artists) assert("Hall and Oates" in Song.artists) + def test_unique_artists(self): + '''all song artists are unique.''' + assert len(Song.artists) == len(set(Song.artists)) + def test_has_genre_count(self): '''keeps count of Songs for each genre.''' assert(Song.genre_count["Rap"] == 1)