示例#1
0
def test_http_album(botmock):
    msg = 'http://open.spotify.com/album/5O8MKoOZoTK1JfD1tAN2TA'
    title = '[Spotify] Organ - Nekrofiilis (2001)'
    assert ('#channel', title) == handle_privmsg(botmock, None, '#channel', msg)
示例#2
0
def test_http_artist(botmock):
    msg = 'http://open.spotify.com/artist/3MXhtYDNuzQQmLfOKFgPiI'
    regex = '\[Spotify\] Einojuhani Rautavaara( \(Genre: \S.+\))?'
    check_re(regex, handle_privmsg(botmock, None, '#channel', msg)[1])
示例#3
0
def test_spotify_track(botmock):
    msg = 'spotify:track:46c5HqyYtOkpjdp193KCln'
    title = '[Spotify] Ultra Bra - Sinä päivänä kun synnyin - Heikko valo'
    assert ('#channel', title) == handle_privmsg(botmock, None, '#channel', msg)
示例#4
0
def test_http_album():
    msg = 'http://open.spotify.com/album/5O8MKoOZoTK1JfD1tAN2TA'
    title = '[Spotify] Organ - Nekrofiilis (2001)'
    eq_(('#channel', title), handle_privmsg(bot, None, '#channel', msg))
示例#5
0
def test_http_artist():
    msg = 'http://open.spotify.com/artist/3MXhtYDNuzQQmLfOKFgPiI'
    regex = '\[Spotify\] Einojuhani Rautavaara( \(Genre: \S.+\))?'
    check_re(regex, handle_privmsg(bot, None, '#channel', msg)[1])
示例#6
0
def test_spotify_track():
    msg = 'spotify:track:46c5HqyYtOkpjdp193KCln'
    title = '[Spotify] Ultra Bra - Sinä päivänä kun synnyin - Heikko valo'
    eq_(('#channel', title), handle_privmsg(bot, None, '#channel', msg))