Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(4)  |  Call(4)  |  Derive(0)  |  Import(0)

src/p/y/Pythagora-HEAD/tests/test_mpdlibrary.py   Pythagora(Download)
    expect = sorted(mpdlibrary.Song(song, library) for song in test_list if song.get('artist') == _name)
    assert sorted(artist.songs) == expect
    expect = sorted(mpdlibrary.Album(song.get('album', 'None'), library)
            for song in test_list if song.get('artist') == _name)
    assert sorted(artist.albums) == expect
def _test_album(_name):
    name = _deduplicate(_name)
    album = mpdlibrary.Album(name, library)
    assert album == name
    expect = sorted(mpdlibrary.Song(song, library) for song in test_list if song.get('album') == _name)
            for song in test_list if song.get('genre') == 'Rock')
    assert sorted(genre.artists) == expect
    expect = sorted(mpdlibrary.Album(song.get('album', 'None'), library)
            for song in test_list if song.get('genre') == 'Rock')
    assert sorted(genre.albums) == expect
            for song in test_list if 'Electronic' in song.get('genre', []))
    assert sorted(genre.artists) == expect
    expect = sorted(mpdlibrary.Album(song.get('album', 'None'), library)
            for song in test_list if 'Electronic' in song.get('genre', []))
    assert sorted(genre.albums) == expect