code: def test_weights_for_airline_averaging():
      """Test weights."""
      y = load_airline()
      y_train, y_test = temporal_train_test_split(y)
  
      forecaster = OnlineEnsembleForecaster(
          [
              (
                  "ses",
                  ExponentialSmoothing(
                      seasonal="multiplicative", sp=12
                  ),
              ),
              (
                  "holt",
                  ExponentialSmoothing(
                      trend="add",
                      damped_trend=False,
                      seasonal="multiplicative",
                      sp=12,
                  ),
              ),
              (
                  "damped_trend",
                  ExponentialSmoothing(
                      trend="add",
                      damped_trend=True,
                      seasonal="multiplicative",
                      sp=12,
                  ),
              ),
          ]
      )
  
      forecaster.fit(y_train)
  
      expected = np.array([1 / 3, 1 / 3, 1 / 3])
      np.testing.assert_allclose(
          forecaster.weights, expected, rtol=1e-8
      )
  
file_path: sktime/sktime/forecasting/online_learning/tests/test_online_learning.py
imports: import numpy
  import pytest
  from sklearn.metrics import mean_squared_error
  from sktime.datasets import load_airline
  from sktime.forecasting.exp_smoothing import ExponentialSmoothing
  from sktime.forecasting.naive import NaiveForecaster
  from sktime.forecasting.online_learning._online_ensemble import OnlineEnsembleForecaster
  from sktime.forecasting.online_learning._prediction_weighted_ensembler import NNLSEnsemble, NormalHedgeEnsemble
  from sktime.split import SlidingWindowSplitter, temporal_train_test_split
  from sktime.tests.test_switch import run_test_for_class
  from sktime.utils.validation._dependencies import _check_soft_dependencies
label_desc: Use image node_id 1 for calling a global function with example usage: test_weights_for_airline_averaging() without return types