code: def test_remove_categories_raises(self, removals):
      cat = Categorical(["a", "b", "a"])
      message = re.escape(
          "removals must all be in old categories: {'c'}"
      )
  
      with pytest.raises(ValueError, match=message):
          cat.remove_categories(removals)
  
imports: import re
  import numpy
  import pytest
  from pandas.compat import PY311
  from pandas import Categorical, CategoricalIndex, DataFrame, Index, Series, StringDtype
  import pandas._testing
  from pandas.core.arrays.categorical import recode_for_categories
label_desc: Use image node_id 18 for calling the TestCategoricalAPI obj's underlying member method code with example usage: obj.test_remove_categories_raises(removals) without return types