code: def test_sanity(data_type):
      im1 = hopper()
  
      data = im1.tobytes()
      if data_type == "memoryview":
          data = memoryview(data)
      im2 = Image.frombytes(im1.mode, im1.size, data)
  
      assert_image_equal(im1, im2)
  
imports: from __future__ import annotations
  import pytest
  from PIL import Image
  from .helper import assert_image_equal, hopper
label_desc: Use image node_id 1 for calling a global function with example usage: test_sanity(data_type) without return types