Convert bake image to a method for testing