### Question:
ImageUtil { public static BufferedImage fillImage(final BufferedImage image, final Color color) { return fillImage(image, color, ColorUtil::isNotFullyTransparent); }  static BufferedImage bufferedImageFromImage(final Image image); static BufferedImage grayscaleOffset(final BufferedImage image, final int offset); static BufferedImage grayscaleOffset(final BufferedImage image, final float percentage); static BufferedImage alphaOffset(final BufferedImage image, final int offset); static BufferedImage alphaOffset(final BufferedImage image, final float percentage); static BufferedImage grayscaleImage(final BufferedImage image); static BufferedImage resizeImage(final BufferedImage image, final int newWidth, final int newHeight); static BufferedImage resizeCanvas(final BufferedImage image, final int newWidth, final int newHeight); static BufferedImage rotateImage(final BufferedImage image, final double theta); static BufferedImage flipImage(final BufferedImage image, final boolean horizontal, final boolean vertical); static BufferedImage outlineImage(final BufferedImage image, final Color color); static BufferedImage outlineImage(final BufferedImage image, final Color color, final Predicate<Color> fillCondition); static BufferedImage outlineImage(final BufferedImage image, final Color color, final Boolean outlineCorners); static BufferedImage outlineImage(final BufferedImage image, final Color color, final Predicate<Color> fillCondition, final Boolean outlineCorners); static BufferedImage getResourceStreamFromClass(final Class c, final String path); static BufferedImage fillImage(final BufferedImage image, final Color color); static SpritePixels getImageSpritePixels(BufferedImage image, Client client);  }### Answer:
@Test public void fillImage() { assertTrue(bufferedImagesEqual(centeredPixel(GRAY), ImageUtil.fillImage(centeredPixel(BLACK), GRAY))); assertTrue(bufferedImagesEqual(solidColor(3, 3, GREEN), ImageUtil.fillImage(solidColor(3, 3, BLACK), GREEN))); assertTrue(bufferedImagesEqual(oneByOne(BLACK_TRANSPARENT), ImageUtil.fillImage(oneByOne(BLACK_TRANSPARENT), WHITE))); BufferedImage expected = solidColor(CORNER_SIZE, CORNER_SIZE, WHITE); expected.setRGB(0, 0, new Color(0, true).getRGB()); assertTrue(bufferedImagesEqual(expected, ImageUtil.fillImage(BLACK_PIXEL_TOP_LEFT, WHITE, ColorUtil::isFullyTransparent))); }
@Test public void fillImage() { assert(bufferedImagesEqual(centeredPixel(GRAY), ImageUtil.fillImage(centeredPixel(BLACK), GRAY))); assert(bufferedImagesEqual(solidColor(3, 3, GREEN), ImageUtil.fillImage(solidColor(3, 3, BLACK), GREEN))); assert(bufferedImagesEqual(oneByOne(BLACK_TRANSPARENT), ImageUtil.fillImage(oneByOne(BLACK_TRANSPARENT), WHITE))); BufferedImage expected = solidColor(CORNER_SIZE, CORNER_SIZE, WHITE); expected.setRGB(0, 0, new Color(0, true).getRGB()); assert(bufferedImagesEqual(expected, ImageUtil.fillImage(BLACK_PIXEL_TOP_LEFT, WHITE, ColorUtil::isFullyTransparent))); }