def test_1(self): """ interpolate_rgb(a, b) converts a and b to RGB colors """ i = interpolate.rgb(Color("steelblue"), Color("brown")) self.assertEqual(i(0), Color("steelblue")) self.assertEqual(i(1), Color("brown"))
def test_1(self): """ interpolate_rgb(a, b) converts a and b to RGB colors """ i = interpolate.rgb( Color("steelblue"), Color("brown")) self.assertEqual(i(0), Color("steelblue")) self.assertEqual(i(1), Color("brown"))
def test_2(self): """ interpolate_rgb(a, b) interpolates in RGB and returns a hexadecimal string """ i = interpolate.rgb(Color("steelblue"), Color("#f00")) self.assertEqual(i(.2), Color("#6b6890"))