code: def test_expanding():
      df = pd.DataFrame(np.random.rand(4, 3), columns=list("abc"))
      df2 = md.DataFrame(df)
  
      with pytest.raises(NotImplementedError):
          _ = df2.expanding(3, center=True)
  
      with pytest.raises(NotImplementedError):
          _ = df2.expanding(3, axis=1)
  
      r = df2.expanding(3, center=False)
      expected = df.expanding(3, center=False)
      assert repr(r) == repr(expected)
  
      assert "b" in dir(r)
  
      with pytest.raises(AttributeError):
          _ = r.d
  
      with pytest.raises(KeyError):
          _ = r["d"]
  
      with pytest.raises(KeyError):
          _ = r["a", "d"]
  
      assert "a" not in dir(r.a)
      assert "c" not in dir(r["a", "b"])
  
imports: import numpy
  import pandas
  import pytest
  from .....None import dataframe
  from .....core import tile
label_desc: Use image node_id 1 for calling a global function with example usage: test_expanding() without return types