code: def test_to_hdf_with_object_column_names_should_fail(
      tmp_path, setup_path, columns
  ):
      # GH9057
      df = DataFrame(
          np.random.default_rng(2).standard_normal((10, 2)),
          columns=columns,
      )
      path = tmp_path / setup_path
      msg = "cannot have non-object label DataIndexableCol"
      with pytest.raises(ValueError, match=msg):
          df.to_hdf(path, key="df", format="table", data_columns=True)
  
imports: import contextlib
  import datetime
  import hashlib
  import tempfile
  import time
  import numpy
  import pytest
  import pandas
  from pandas import DataFrame, DatetimeIndex, Index, MultiIndex, Series, Timestamp, concat, date_range, period_range, timedelta_range
  import pandas._testing
  from pandas.tests.io.pytables.common import _maybe_remove, ensure_clean_store
  from pandas.io.pytables import HDFStore, read_hdf
label_desc: Use image node_id 38 for calling a global function with example usage: test_to_hdf_with_object_column_names_should_fail(tmp_path, setup_path, columns) without return types