예제 #1
0
 def test_ahead_behind__mismatched(self):
     self.assertEqual(
         term_color(u"↑2", tcolors.AHEAD) + term_color(u"↓3", tcolors.BEHIND),
         ahead_behind(2, 3)
     )
예제 #2
0
 def test_ahead_behind__ahead(self):
     self.assertEqual(term_color(u"↑1", tcolors.AHEAD), ahead_behind(1, 0))
예제 #3
0
 def test_ahead_behind__behind(self):
     self.assertEqual(term_color(u"↓2", tcolors.BEHIND), ahead_behind(0, 2))
예제 #4
0
 def test_ahead_behind__upto_date(self):
     self.assertEqual(u"", ahead_behind(0, 0))