def METHOD_NAME(params):
    cmap_1 = CategoricalColormap(**params)
    cmap_json = cmap_1.json()
    json_dict = json.loads(cmap_json)
    cmap_2 = CategoricalColormap(**json_dict)
    assert cmap_1 == cmap_2