code: def test_labels(right, breaks, closed):
      arr = np.tile(np.arange(0, 1.01, 0.1), 4)
  
      result, bins = cut(arr, 4, retbins=True, right=right)
      ex_levels = IntervalIndex.from_breaks(breaks, closed=closed)
      tm.assert_index_equal(result.categories, ex_levels)
  
imports: import numpy
  import pytest
  import pandas
  from pandas import Categorical, DataFrame, DatetimeIndex, Index, Interval, IntervalIndex, Series, TimedeltaIndex, Timestamp, cut, date_range, interval_range, isna, qcut, timedelta_range, to_datetime
  import pandas._testing
  from pandas.api.types import CategoricalDtype
  import pandas.core.reshape.tile
label_desc: Use image node_id 15 for calling a global function with example usage: test_labels(right, breaks, closed) without return types