[PR #500] [MERGED] Refactor two unittests that could fail for some users and make them more generic #917

Closed
opened 2026-02-28 00:02:37 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/spotipy-dev/spotipy/pull/500
Author: @ysinjab
Created: 5/27/2020
Status: Merged
Merged: 5/29/2020
Merged by: @stephanebruckert

Base: masterHead: refactor-unittests-to-accept-generic-user


📝 Commits (1)

  • 7906417 Refactor two unittests that could fail for

📊 Changes

1 file changed (+6 additions, -4 deletions)

View changed files

📝 tests/integration/test_user_endpoints.py (+6 -4)

📄 Description

When I used my user in spotify to run unit tests those unittests have failed. Changes are:

  • test_user_follows_and_unfollows_artist: get the current number of followed artists, follow some new artists. New number should be the current number plus the number of the new followed artists. Unfollow those artists and check if the number get back again to original.
  • test_user_playlist_tracks: Between all my playlists check only the playlist created by the test.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/spotipy-dev/spotipy/pull/500 **Author:** [@ysinjab](https://github.com/ysinjab) **Created:** 5/27/2020 **Status:** ✅ Merged **Merged:** 5/29/2020 **Merged by:** [@stephanebruckert](https://github.com/stephanebruckert) **Base:** `master` ← **Head:** `refactor-unittests-to-accept-generic-user` --- ### 📝 Commits (1) - [`7906417`](https://github.com/spotipy-dev/spotipy/commit/7906417c1d96f940552b7d63900cadd3a72edf92) Refactor two unittests that could fail for ### 📊 Changes **1 file changed** (+6 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `tests/integration/test_user_endpoints.py` (+6 -4) </details> ### 📄 Description When I used my user in spotify to run unit tests those unittests have failed. Changes are: - **test_user_follows_and_unfollows_artist**: get the current number of followed artists, follow some new artists. New number should be the current number plus the number of the new followed artists. Unfollow those artists and check if the number get back again to original. - **test_user_playlist_tracks**: Between all my playlists check only the playlist created by the test. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-28 00:02:37 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/spotipy#917
No description provided.