code: def _check_op(
      self,
      ser: pd.Series,
      op,
      other,
      op_name: str,
      exc=NotImplementedError,
  ):
      # Check that the Series/DataFrame arithmetic/comparison method matches
      #  the pointwise result from _combine.
  
      if exc is None:
          result = op(ser, other)
          expected = self._combine(ser, other, op)
          expected = self._cast_pointwise_result(
              op_name, ser, other, expected
          )
          assert isinstance(result, type(ser))
          tm.assert_equal(result, expected)
      else:
          with pytest.raises(exc):
              op(ser, other)
  
imports: from __future__ import annotations
  from typing import final
  import numpy
  import pytest
  from pandas._config import using_pyarrow_string_dtype
  from pandas.core.dtypes.common import is_string_dtype
  import pandas
  import pandas._testing
  from pandas.core import ops
label_desc: Use image node_id 6 for calling the BaseOpsUtil obj's underlying member method code with example usage: obj._check_op(ser, op, other, op_name, exc) without return types