code: def test_contains(setup_path):
      with ensure_clean_store(setup_path) as store:
          store["a"] = Series(
              np.arange(10, dtype=np.float64),
              index=date_range("2020-01-01", periods=10),
          )
          store["b"] = DataFrame(
              1.1 * np.arange(120).reshape((30, 4)),
              columns=Index(list("ABCD"), dtype=object),
              index=Index([f"i-{i}" for i in range(30)], dtype=object),
          )
          store["foo/bar"] = DataFrame(
              1.1 * np.arange(120).reshape((30, 4)),
              columns=Index(list("ABCD"), dtype=object),
              index=Index([f"i-{i}" for i in range(30)], dtype=object),
          )
          assert "a" in store
          assert "b" in store
          assert "c" not in store
          assert "foo/bar" in store
          assert "/foo/bar" in store
          assert "/foo/b" not in store
          assert "bar" not in store
  
          # gh-2694: tables.NaturalNameWarning
          with tm.assert_produces_warning(
              tables.NaturalNameWarning, check_stacklevel=False
          ):
              store["node())"] = DataFrame(
                  1.1 * np.arange(120).reshape((30, 4)),
                  columns=Index(list("ABCD"), dtype=object),
                  index=Index(
                      [f"i-{i}" for i in range(30)], dtype=object
                  ),
              )
          assert "node())" in store
  
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 5 for calling a global function with example usage: test_contains(setup_path) without return types