def METHOD_NAME():
    """Test that we can serialize a PIL image created in-memory with a lossless compression."""
    default_format = "PNG"
    img = PILImage.new("RGB", (1000, 600), color=(255, 255, 255))
    # Image should have no format information
    assert img.format is None
    # We should be able to serialize the image without any issues; we test .proto() since it's used
    # in the underlying conversion to alternate serialized formats, e.g., .json() also.
    dm_image = v.data_model.Image(img)
    proto_img = dm_image.to_proto()
    assert dm_image._backend._export_format == default_format
    # Then, if we reconstruct from the serialized proto, it should be
    # reloaded as a PNG because it was serialized as a PNG.
    assert (
        v.data_model.Image.from_proto(proto_img)._backend._export_format
        == default_format
    )