class_docstr: Tests the color_palette function.
docstr: Test that bad color names raise an exception
docstr_tok: ["Test","that","bad","color","names","raise","an","exception"]
code: def test_bad_palette_colors(self):
      """
      Test that bad color names raise an exception
      """
  
      pal = ["red", "blue", "iamnotacolor"]
      with pytest.raises(ValueError):
          color_palette(pal)
  
      with pytest.raises(YellowbrickValueError):
          color_palette(pal)
  
imports: import pytest
  import numpy
  import matplotlib
  from yellowbrick.exceptions import *
  from yellowbrick.style.palettes import *
  from yellowbrick.style.colors import get_color_cycle
  from yellowbrick.style.rcmod import set_aesthetic, set_palette
  from yellowbrick.style.palettes import color_sequence, color_palette
  from yellowbrick.style.palettes import ColorPalette, PALETTES, SEQUENCES
  from tests.base import VisualTestCase
label_desc: Use image node_id 8 for calling the TestColorPaletteFunction obj's underlying member method code with example usage: obj.test_bad_palette_colors() without return types