code: def test_loading_multiple_palettes(path, mode):
      with Image.open(path) as im:
          assert im.mode == "P"
          first_frame_colors = im.palette.colors.keys()
          original_color = im.convert("RGB").load()[0, 0]
  
          im.seek(1)
          assert im.mode == mode
          if mode == "RGBA":
              im = im.convert("RGB")
  
          # Check a color only from the old palette
          assert im.load()[0, 0] == original_color
  
          # Check a color from the new palette
          assert im.load()[24, 24] not in first_frame_colors
  
imports: from io import BytesIO
  import pytest
  from PIL import GifImagePlugin, Image, ImageDraw, ImagePalette, features
  from .helper import assert_image_equal, assert_image_equal_tofile, assert_image_similar, hopper, is_pypy, netpbm_available
label_desc: Use image node_id 12 for calling a global function with example usage: test_loading_multiple_palettes(path, mode) without return types