code: def test_col_spec():
      a1 = ColSpec("string", "a")
      a2 = ColSpec(DataType.string, "a")
      a3 = ColSpec(DataType.integer, "a")
      assert a1 != a3
      b1 = ColSpec(DataType.string, "b")
      assert b1 != a1
      assert a1 == a2
      with pytest.raises(
          MlflowException, match="Unsupported type 'unsupported'"
      ):
          ColSpec("unsupported")
      a4 = ColSpec(**a1.to_dict())
      assert a4 == a1
      assert ColSpec(**json.loads(json.dumps(a1.to_dict()))) == a1
      a5 = ColSpec("string")
      a6 = ColSpec("string", None)
      assert a5 == a6
      assert ColSpec(**json.loads(json.dumps(a5.to_dict()))) == a5
  
imports: import datetime
  import json
  import math
  import re
  import numpy
  import pandas
  import pyspark
  import pyspark.sql.types
  import pytest
  from scipy.sparse import csc_matrix, csr_matrix
  from mlflow.exceptions import MlflowException
  from mlflow.models.utils import _enforce_tensor_spec
  from mlflow.pyfunc import _parse_spark_datatype
  from mlflow.types import DataType
  from mlflow.types.schema import Array, ColSpec, Object, ParamSchema, ParamSpec, Property, Schema, TensorSpec
  from mlflow.types.utils import _get_tensor_shape, _infer_colspec_type, _infer_param_schema, _infer_schema, _validate_input_dictionary_contains_only_strings_and_lists_of_strings
label_desc: Use image node_id 2 for calling a global function with example usage: test_col_spec() without return types