code: def test_sanity():
      with open("Tests/images/test.gpl", "rb") as fp:
          GimpPaletteFile(fp)
  
      with open("Tests/images/hopper.jpg", "rb") as fp:
          with pytest.raises(SyntaxError):
              GimpPaletteFile(fp)
  
      with open("Tests/images/bad_palette_file.gpl", "rb") as fp:
          with pytest.raises(SyntaxError):
              GimpPaletteFile(fp)
  
      with open("Tests/images/bad_palette_entry.gpl", "rb") as fp:
          with pytest.raises(ValueError):
              GimpPaletteFile(fp)
  
imports: from __future__ import annotations
  import pytest
  from PIL.GimpPaletteFile import GimpPaletteFile
label_desc: Use image node_id 1 for calling a global function with example usage: test_sanity() without return types