code: def test_writing_other_types_to_ascii(value, expected, tmp_path):
      info = TiffImagePlugin.ImageFileDirectory_v2()
  
      tag = TiffTags.TAGS_V2[271]
      assert tag.type == TiffTags.ASCII
  
      info[271] = value
  
      im = hopper()
      out = str(tmp_path / "temp.tiff")
      im.save(out, tiffinfo=info)
  
      with Image.open(out) as reloaded:
          assert reloaded.tag_v2[271] == expected
  
imports: from __future__ import annotations
  import io
  import struct
  import pytest
  from PIL import Image, TiffImagePlugin, TiffTags
  from PIL.TiffImagePlugin import IFDRational
  from .helper import assert_deep_equal, hopper
label_desc: Use image node_id 7 for calling a global function with example usage: test_writing_other_types_to_ascii(value, expected, tmp_path) without return types