code: def test_plot_model_data_raises(load_pos_and_neg_data, plot):
      """Tests the plot_model functionality when it raises an exception
      on data plots (i.e. estimator is not passed)
      """
      exp = TSForecastingExperiment()
      fh = np.arange(1, 13)
      fold = 2
  
      ######################
      # OOP Approach ####
      ######################
  
      exp.setup(
          data=load_pos_and_neg_data,
          fh=fh,
          fold=fold,
          fold_strategy="sliding",
          verbose=False,
          session_id=42,
      )
  
      with pytest.raises(ValueError) as errmsg:
          # Some code that produces a value error
          exp.plot_model(plot=plot)
  
      # Capture Error message
      exceptionmsg = errmsg.value.args[0]
  
      # Check exact error received
      assert (
          f"Plot type '{plot}' is not supported when estimator is not provided"
          in exceptionmsg
      )
  
file_path: pycaret/tests/test_time_series_plots.py
imports: import os
  import sys
  import numpy
  import pytest
  from time_series_test_utils import _ALL_PLOTS_DATA, _ALL_PLOTS_ESTIMATOR, _ALL_PLOTS_ESTIMATOR_NOT_DATA, _return_all_plots_estimator_ts_results, _return_data_with_without_period_index, _return_model_names_for_plots_stats
  from pycaret.datasets import get_data
  from pycaret.time_series import TSForecastingExperiment
label_desc: Use image node_id 3 for calling a global function with example usage: test_plot_model_data_raises(load_pos_and_neg_data, plot) without return types