def METHOD_NAME(self):
    for color in [1.0, 0.0, 0.5]:
        with self.subTest(color=color):
            orig = self.solid_bgra32(self.size, color)
            img = GraphicsContext(orig, pix_format="bgra32")
            gc = GraphicsContext(self.size, pix_format="bgra32")
            amb_alpha = 0.5
            gc.set_alpha(amb_alpha)
            gc.draw_image(img)
            actual = gc.bmp_array
            gc_background = self.solid_bgra32(self.size, 1.0)
            orig = self.solid_bgra32(self.size, color)
            desired = self.alpha_blend(
                gc_background, orig, ambient_alpha=amb_alpha
            )
            # alpha blending is approximate, allow channel differences of to 2.
            self.assert_images_close(desired, actual, diff_allowed=slop_allowed)