Пример #1
0
 def test_validate_color2(self):
     try:
         validate_color(55555)
     except TypeError:
         pass
     else:
         self.fail("Expected TypeError")
Пример #2
0
 def test_validate_color1(self):
     self.assertEqual(validate_color("not a 5olor"), None)
Пример #3
0
 def test_validate_color0(self):
     self.assertEqual(validate_color("not a color"), "not a color")