class TestDiscoball(unittest.TestCase): def setUp(self): self.dball = Discoball([re.compile('\+\w+')], "one", "all") def testNoMatch(self): line = 'no match' self.assertEqual(line, self.dball.colorize(line)) def testSimpleMatch(self): line = '+tag' expected = str(underline(blue(line))) self.assertEqual(expected, self.dball.colorize(line))
def setUp(self): self.dball = Discoball([re.compile('\+\w+')], "one", "all")