code: def test_casting_to_an_enum_from_categorical_nonexistent() -> None:
      with pytest.raises(
          pl.ComputeError,
          match=("value 'c' is not present in Enum"),
      ):
          pl.Series([None, "a", "b", "c"], dtype=pl.Categorical).cast(
              pl.Enum(["a", "b"])
          )
  
imports: import operator
  from datetime import date
  from textwrap import dedent
  from typing import Any, Callable
  import pytest
  import polars
  from polars import StringCache
  from polars.testing import assert_series_equal
label_desc: Use image node_id 10 for calling a global function with example usage: test_casting_to_an_enum_from_categorical_nonexistent() without return types