class_docstr: Test ability to marshall metric protos and invalid input.
class_docstr_tok: ["Test","ability","to","marshall","metric","protos","and","invalid","input","."]
docstr: Test that metric delta colors returns the correct proto value.
docstr_tok: ["Test","that","metric","delta","colors","returns","the","correct","proto","value","."]
code: def test_delta_color(self):
      """Test that metric delta colors returns the correct proto value."""
      arg_delta_values = [
          "-123",
          -123,
          -1.23,
          "123",
          123,
          1.23,
          None,
          "",
      ]
      arg_delta_color_values = [
          "normal",
          "inverse",
          "off",
          "normal",
          "inverse",
          "off",
          "normal",
          "normal",
      ]
      color_values = [
          MetricProto.MetricColor.RED,
          MetricProto.MetricColor.GREEN,
          MetricProto.MetricColor.GRAY,
          MetricProto.MetricColor.GREEN,
          MetricProto.MetricColor.RED,
          MetricProto.MetricColor.GRAY,
          MetricProto.MetricColor.GRAY,
          MetricProto.MetricColor.GRAY,
      ]
      direction_values = [
          MetricProto.MetricDirection.DOWN,
          MetricProto.MetricDirection.DOWN,
          MetricProto.MetricDirection.DOWN,
          MetricProto.MetricDirection.UP,
          MetricProto.MetricDirection.UP,
          MetricProto.MetricDirection.UP,
          MetricProto.MetricDirection.NONE,
          MetricProto.MetricDirection.NONE,
      ]
  
      for (
          arg_delta_value,
          arg_delta_color_value,
          color_value,
          direction_value,
      ) in zip(
          arg_delta_values,
          arg_delta_color_values,
          color_values,
          direction_values,
      ):
          st.metric(
              "label_test",
              "4312",
              arg_delta_value,
              arg_delta_color_value,
          )
  
          c = self.get_delta_from_queue().new_element.metric
          self.assertEqual(c.label, "label_test")
          self.assertEqual(c.color, color_value)
          self.assertEqual(c.direction, direction_value)
  
imports: from parameterized import parameterized
  import streamlit
  from streamlit.errors import StreamlitAPIException
  from streamlit.proto.LabelVisibilityMessage_pb2 import LabelVisibilityMessage
  from streamlit.proto.Metric_pb2 import Metric
  from streamlit.type_util import _LOGGER
  from tests.delta_generator_test_case import DeltaGeneratorTestCase
label_desc: Use image node_id 7 for calling the MetricTest obj's underlying member method code with example usage: obj.test_delta_color() without return types