code: def test_output_backtesting_forecaster_multiseries_ForecasterAutoregMultiSeries_refit_int_interval_yes_exog_yes_remainder_with_mocked(
      forecaster,
  ):
      """
      Test output of backtesting_forecaster_multiseries in ForecasterAutoregMultiSeries
      and ForecasterAutoregMultiSeriesCustom with refit int, interval, gap,
      with mocked using exog and intervals (mocked done in Skforecast v0.9.0).
      """
      refit = 2
      n_validation = 20
      steps = 2
  
      (
          metrics_levels,
          backtest_predictions,
      ) = backtesting_forecaster_multiseries(
          forecaster=forecaster,
          series=series,
          steps=steps,
          levels=None,
          metric="mean_absolute_error",
          initial_train_size=len(series) - n_validation,
          gap=0,
          allow_incomplete_fold=False,
          refit=refit,
          fixed_train_size=True,
          exog=series["l1"].rename("exog_1"),
          interval=[5, 95],
          n_boot=150,
          random_state=123,
          in_sample_residuals=True,
          verbose=False,
      )
  
      expected_metric = pd.DataFrame(
          {
              "levels": ["l1", "l2"],
              "mean_absolute_error": [
                  0.13341641696298234,
                  0.2532943228025243,
              ],
          }
      )
      expected_predictions = pd.DataFrame(
          data=np.array(
              [
                  [
                      3.62121311e-01,
                      1.50820320e-01,
                      5.93493644e-01,
                      3.65807102e-01,
                      -1.66846896e-01,
                      7.41872674e-01,
                  ],
                  [
                      4.75603912e-01,
                      2.64338068e-01,
                      7.55477618e-01,
                      4.77660870e-01,
                      -2.09016888e-02,
                      8.50640767e-01,
                  ],
                  [
                      4.78856340e-01,
                      2.67555349e-01,
                      7.10228673e-01,
                      4.79828611e-01,
                      -5.28253867e-02,
                      8.55894183e-01,
                  ],
                  [
                      4.97626059e-01,
                      2.86360215e-01,
                      7.77499764e-01,
                      4.98181879e-01,
                      -3.80679351e-04,
                      8.71161776e-01,
                  ],
                  [
                      4.57502853e-01,
                      2.34854548e-01,
                      6.90295515e-01,
                      4.93394245e-01,
                      -8.59476649e-02,
                      8.26877562e-01,
                  ],
                  [
                      4.19762089e-01,
                      1.89123646e-01,
                      5.98698797e-01,
                      4.37345761e-01,
                      -2.47590943e-02,
                      8.09946951e-01,
                  ],
                  [
                      4.64704145e-01,
                      2.42055840e-01,
                      6.97496807e-01,
                      4.95977483e-01,
                      -8.33644270e-02,
                      8.29460800e-01,
                  ],
                  [
                      6.27792451e-01,
                      3.97154009e-01,
                      8.06729160e-01,
                      6.80737238e-01,
                      2.18632382e-01,
                      1.05333843e00,
                  ],
                  [
                      5.87334375e-01,
                      3.26921031e-01,
                      8.69376004e-01,
                      6.65280778e-01,
                      1.23472110e-01,
                      1.05838353e00,
                  ],
                  [
                      4.53164888e-01,
                      1.98770357e-01,
                      7.31112253e-01,
                      5.17357914e-01,
                      -3.46981422e-02,
                      9.17114685e-01,
                  ],
                  [
                      4.91347698e-01,
                      2.30934354e-01,
                      7.73389327e-01,
                      5.56066550e-01,
                      1.42578818e-02,
                      9.49169307e-01,
                  ],
                  [
                      3.58133021e-01,
                      1.03738489e-01,
                      6.36080385e-01,
                      3.94861192e-01,
                      -1.57194865e-01,
                      7.94617962e-01,
                  ],
                  [
                      4.23074894e-01,
                      1.46402575e-01,
                      6.85243368e-01,
                      4.56570627e-01,
                      -8.44076809e-02,
                      9.13597456e-01,
                  ],
                  [
                      4.77639455e-01,
                      2.00288697e-01,
                      7.45269910e-01,
                      4.52788025e-01,
                      -6.08964382e-02,
                      9.16193940e-01,
                  ],
                  [
                      5.90866263e-01,
                      3.14193944e-01,
                      8.53034737e-01,
                      6.06068550e-01,
                      6.50902424e-02,
                      1.06309538e00,
                  ],
                  [
                      4.29943139e-01,
                      1.52592381e-01,
                      6.97573594e-01,
                      4.22379461e-01,
                      -9.13050017e-02,
                      8.85785376e-01,
                  ],
                  [
                      4.71297777e-01,
                      1.92467142e-01,
                      7.32960612e-01,
                      5.16307783e-01,
                      -5.04225194e-02,
                      9.64821047e-01,
                  ],
                  [
                      6.45316619e-01,
                      4.47497018e-01,
                      9.25177996e-01,
                      6.51701762e-01,
                      1.69673821e-01,
                      1.01740457e00,
                  ],
                  [
                      5.42727946e-01,
                      2.63897311e-01,
                      8.04390781e-01,
                      5.10069712e-01,
                      -5.66605897e-02,
                      9.58582976e-01,
                  ],
                  [
                      5.30915933e-01,
                      3.33096333e-01,
                      8.10777311e-01,
                      5.43494604e-01,
                      6.14666630e-02,
                      9.09197415e-01,
                  ],
              ]
          ),
          columns=[
              "l1",
              "l1_lower_bound",
              "l1_upper_bound",
              "l2",
              "l2_lower_bound",
              "l2_upper_bound",
          ],
          index=pd.RangeIndex(start=30, stop=50, step=1),
      )
  
      pd.testing.assert_frame_equal(expected_metric, metrics_levels)
      pd.testing.assert_frame_equal(
          expected_predictions, backtest_predictions
      )
  
imports: import re
  import pytest
  import numpy
  import pandas
  from sklearn.linear_model import Ridge
  from sklearn.metrics import mean_absolute_error
  from skforecast.exceptions import IgnoredArgumentWarning
  from skforecast.ForecasterAutoreg import ForecasterAutoreg
  from skforecast.ForecasterAutoregMultiSeries import ForecasterAutoregMultiSeries
  from skforecast.ForecasterAutoregMultiSeriesCustom import ForecasterAutoregMultiSeriesCustom
  from skforecast.ForecasterAutoregMultiVariate import ForecasterAutoregMultiVariate
  from skforecast.model_selection_multiseries import backtesting_forecaster_multiseries
  from skforecast.model_selection_multiseries import backtesting_forecaster_multivariate
  from .fixtures_model_selection_multiseries import series
label_desc: Use image node_id 18 for calling a global function with example usage: test_output_backtesting_forecaster_multiseries_ForecasterAutoregMultiSeries_refit_int_interval_yes_exog_yes_remainder_with_mocked(forecaster) without return types