Esempio n. 1
0
 def test_parse_for_command__VTHelp_only(self):
     msg = "!vthelp"
     cmd = bot.parse_for_command(msg, self.author, 1)
     self.assertEqual(cmd, bot.Commands.VTHELP)
Esempio n. 2
0
 def test_parse_for_command__VTCT_only(self):
     msg = "!vtct"
     cmd = bot.parse_for_command(msg, self.author, 1)
     self.assertEqual(cmd, bot.Commands.VTCT)
Esempio n. 3
0
 def test_parse_for_command__VTBan_only(self):
     msg = "!vtban"
     cmd = bot.parse_for_command(msg, self.author, 1)
     self.assertEqual(cmd, bot.Commands.NEEDADMIN)
Esempio n. 4
0
 def test_parse_for_command__VT_before(self):
     msg = "!vt testing"
     cmd = bot.parse_for_command(msg, self.author, 1)
     self.assertEqual(cmd, bot.Commands.VT)
Esempio n. 5
0
 def test_parse_for_command__VT_after(self):
     msg = "test !vt"
     cmd = bot.parse_for_command(msg, self.author, 1)
     self.assertEqual(cmd, bot.Commands.NOCOMMAND)
Esempio n. 6
0
 def test_parse_for_command__VTSilence_after(self):
     msg = "!vtalert test"
     cmd = bot.parse_for_command(msg, self.author, 1)
     self.assertEqual(cmd, bot.Commands.VTALERT)
Esempio n. 7
0
 def test_parse_for_command__VTSilence_typo(self):
     msg = "!vtsience"
     cmd = bot.parse_for_command(msg, self.author, 1)
     self.assertNotEqual(cmd, bot.Commands.VTSILENCE)