Example #1
0
 def test_next_filter(self):
     ircbot.FILTERS = [self.h_next, self.h_count]
     self.assertEquals("5", ircbot.parse("pocet"))
Example #2
0
 def test_replace_filter(self):
     ircbot.FILTERS = [self.h_replace, self.h_count]
     self.assertEquals("7", ircbot.parse("pocet"))
Example #3
0
 def test_nothing(self):
     self.assertEquals(None, ircbot.parse("nothing test"))
Example #4
0
 def test_command(self):
     ircbot.FILTERS = []
     self.assertEquals("echo bot", ircbot.parse("echo bot"))
Example #5
0
 def test_unknown(self):
     self.assertEquals("unknown test", ircbot.parse("unknown test"))
Example #6
0
 def test_echo(self):
     self.assertEquals("echo bot", ircbot.parse("echo bot"))
Example #7
0
	def test_no_command_no_filter(self):
		self.assertEqual(ircbot.parse("foo"), "foo")
Example #8
0
	def test_f_replace_secret_with_hashes(self):
		self.assertEqual(ircbot.parse("the secret is secret"), "the ###### is ######")
		self.assertEqual(ircbot.parse("foo bar"), "foo bar")
Example #9
0
	def test_cmd_say_hello(self):
		self.assertEqual(ircbot.parse("hello"), "hello to you too")