Skip to content

Commit

Permalink
mpd: Test that "list album foo" responds correctly
Browse files Browse the repository at this point in the history
Previously, test_list_album_with_artist_name would only test that the
command didn't fail. Now it also checks that the response is correct.
That is, that the response contains albums.

This makes the test detect the error reported in #817.

(cherry picked from commit 9771eda)
  • Loading branch information
trygveaa authored and jodal committed Aug 5, 2014
1 parent 9dc8038 commit c798257
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/mpd/protocol/test_music_db.py
Expand Up @@ -880,7 +880,11 @@ def test_list_album_without_quotes_and_capitalized(self):
self.assertInResponse('OK')

def test_list_album_with_artist_name(self):
self.backend.library.dummy_find_exact_result = SearchResult(
tracks=[Track(album=Album(name='foo'))])

self.sendRequest('list "album" "anartist"')
self.assertInResponse('Album: foo')
self.assertInResponse('OK')

def test_list_album_with_artist_name_without_filter_value(self):
Expand Down

0 comments on commit c798257

Please sign in to comment.