code: def test_create_train_X_y_TypeError_when_series_not_dataframe():
      """
      Test TypeError is raised when series is not a pandas DataFrame.
      """
      forecaster = ForecasterAutoregMultiSeries(
          LinearRegression(), lags=3
      )
      series = pd.Series(np.arange(7))
  
      err_msg = re.escape(
          f"`series` must be a pandas DataFrame. Got {type(series)}."
      )
      with pytest.raises(TypeError, match=err_msg):
          forecaster.create_train_X_y(series=series)
  
imports: import re
  import pytest
  import numpy
  import pandas
  from skforecast.ForecasterAutoregMultiSeries import ForecasterAutoregMultiSeries
  from skforecast.exceptions import MissingValuesExogWarning
  from sklearn.linear_model import LinearRegression
  from sklearn.compose import ColumnTransformer
  from sklearn.preprocessing import StandardScaler
  from sklearn.preprocessing import OneHotEncoder
label_desc: Use image node_id 3 for calling a global function with example usage: test_create_train_X_y_TypeError_when_series_not_dataframe() without return types