MCPcopy Index your code
hub / github.com/python/cpython / checkImgTrans

Method checkImgTrans

Lib/test/test_tkinter/test_images.py:459–464  ·  view source on GitHub ↗
(self, image, expected)

Source from the content-addressed store, hash-verified

457 self.assertEqual(image2.get(1*3+2, 2*3+2), image.get(1*2+2, 2*2+3))
458
459 def checkImgTrans(self, image, expected):
460 actual = {(x, y)
461 for x in range(image.width())
462 for y in range(image.height())
463 if image.transparency_get(x, y)}
464 self.assertEqual(actual, expected)
465
466 def test_copy_replace_compositingrule(self):
467 image1 = tkinter.PhotoImage(master=self.root, width=2, height=2)

Callers 1

Calls 4

heightMethod · 0.80
transparency_getMethod · 0.80
widthMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected