Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GHA integration tests #876

Merged
merged 24 commits into from Nov 1, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/integration_tests.yml
Expand Up @@ -15,7 +15,7 @@ jobs:
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
python-version: ${{ env.PYTHON_VERSION }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Expand Up @@ -9,7 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Added

* Integration tests workflow
* Integration tests via GHA (non-user endpoints)

## [2.21.0] - 2022-09-26

Expand Down
Empty file.
Expand Up @@ -224,12 +224,13 @@ def test_artist_albums(self):
self.assertTrue('items' in results)
self.assertTrue(len(results['items']) > 0)

found = False
for album in results['items']:
if album['name'] == 'Hurley':
found = True
def find_album():
for album in results['items']:
if album['name'] == 'Death to False Metal':
return True
return False

self.assertTrue(found)
self.assertTrue(find_album())

def test_search_timeout(self):
client_credentials_manager = SpotifyClientCredentials()
Expand All @@ -240,6 +241,7 @@ def test_search_timeout(self):
self.assertRaises((requests.exceptions.Timeout, requests.exceptions.ConnectionError),
lambda: sp.search(q='my*', type='track'))

@unittest.skip("flaky test, need a better method to test retries")
def test_max_retries_reached_get(self):
spotify_no_retry = Spotify(
client_credentials_manager=SpotifyClientCredentials(),
Expand Down
Empty file.