code: def test_wrong_num_labels():
      msg = "Bin labels must be one fewer than the number of bin edges"
      data = [0.2, 1.4, 2.5, 6.2, 9.7, 2.1]
  
      with pytest.raises(ValueError, match=msg):
          cut(data, [0, 1, 10], labels=["foo", "bar", "baz"])
  
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 10 for calling a global function with example usage: test_wrong_num_labels() without return types