def colorspaces_converted_should_not_raise (self, prop):
fails = 0
x = 0
for c in rgba_combos_Color_generator():
x += 1
other = pygame.Color(0)
try:
setattr(other, prop, getattr(c, prop))
#eg other.hsla = c.hsla
except ValueError:
fails += 1
self.assert_(x > 0, "x is combination counter, 0 means no tests!")
self.assert_((fails, x) == (0, x))
评论列表
文章目录