code: def test_wrong_mode(self):
      with pytest.raises(ValueError, match="wrong mode"):
          im = Image.new("L", (10, 10), 0)
          im.im.color_lut_3d(
              "RGB", Image.LINEAR, *self.generate_identity_table(3, 3)
          )
  
      with pytest.raises(ValueError, match="wrong mode"):
          im = Image.new("RGB", (10, 10), 0)
          im.im.color_lut_3d(
              "L", Image.LINEAR, *self.generate_identity_table(3, 3)
          )
  
      with pytest.raises(ValueError, match="wrong mode"):
          im = Image.new("L", (10, 10), 0)
          im.im.color_lut_3d(
              "L", Image.LINEAR, *self.generate_identity_table(3, 3)
          )
  
      with pytest.raises(ValueError, match="wrong mode"):
          im = Image.new("RGB", (10, 10), 0)
          im.im.color_lut_3d(
              "RGBA", Image.LINEAR, *self.generate_identity_table(3, 3)
          )
  
      with pytest.raises(ValueError, match="wrong mode"):
          im = Image.new("RGB", (10, 10), 0)
          im.im.color_lut_3d(
              "RGB", Image.LINEAR, *self.generate_identity_table(4, 3)
          )
  
imports: from array import array
  import pytest
  from PIL import Image, ImageFilter
  from .helper import assert_image_equal
label_desc: Use image node_id 4 for calling the TestColorLut3DCoreAPI obj's underlying member method code with example usage: obj.test_wrong_mode() without return types