Awesome IRC bot
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

12 lines
432 B

  1. from pyircbot import common
  2. def test_parse_line():
  3. assert common.parse_irc_line(":chuck!~chuck@foobar PRIVMSG #jesusandhacking :asdf") == \
  4. ('PRIVMSG', ['#jesusandhacking'], 'chuck!~chuck@foobar', "asdf")
  5. def test_parse_notrailing():
  6. assert common.parse_irc_line(":chuck!~chuck@foobar MODE #jesusandhacking -o asciibot") == \
  7. ('MODE', ['#jesusandhacking', '-o', 'asciibot'], 'chuck!~chuck@foobar', None)