code: def test_save(tmp_path):
      temp_file = str(tmp_path / "temp.icns")
  
      with Image.open(TEST_FILE) as im:
          im.save(temp_file)
  
      with Image.open(temp_file) as reread:
          assert reread.mode == "RGBA"
          assert reread.size == (1024, 1024)
          assert reread.format == "ICNS"
  
      file_length = os.path.getsize(temp_file)
      with open(temp_file, "rb") as fp:
          fp.seek(4)
          assert _binary.i32be(fp.read(4)) == file_length
  
file_path: pillow-simd/Tests/test_file_icns.py
imports: import io
  import os
  import pytest
  from PIL import IcnsImagePlugin, Image, _binary, features
  from .helper import assert_image_equal, assert_image_similar_tofile
label_desc: Use image node_id 2 for calling a global function with example usage: test_save(tmp_path) without return types