code: def test_populate_uncertainty_params():
      model = ConstantBaseForecastEstimator()
      model.time_col_ = TIME_COL
      model.value_col_ = VALUE_COL
  
      # No ``value_col`` or ``residual_col``.
      uncertainty_dict = dict(
          uncertainty_method=UncertaintyMethodEnum.simple_conditional_residuals.name,
          params=dict(),
      )
      assert model._populate_uncertainty_params(
          uncertainty_dict=uncertainty_dict
      ) == dict(
          uncertainty_method=UncertaintyMethodEnum.simple_conditional_residuals.name,
          params=dict(value_col=VALUE_COL, residual_col="residual_col"),
      )
  
      # No ``residual_col``.
      uncertainty_dict = dict(
          uncertainty_method=UncertaintyMethodEnum.simple_conditional_residuals.name,
          params=dict(value_col="some_col"),
      )
      assert model._populate_uncertainty_params(
          uncertainty_dict=uncertainty_dict
      ) == dict(
          uncertainty_method=UncertaintyMethodEnum.simple_conditional_residuals.name,
          params=dict(
              value_col="some_col", residual_col="residual_col"
          ),
      )
  
      # No ``value_col``.
      uncertainty_dict = dict(
          uncertainty_method=UncertaintyMethodEnum.simple_conditional_residuals.name,
          params=dict(residual_col="some_col"),
      )
      assert model._populate_uncertainty_params(
          uncertainty_dict=uncertainty_dict
      ) == dict(
          uncertainty_method=UncertaintyMethodEnum.simple_conditional_residuals.name,
          params=dict(value_col=VALUE_COL, residual_col="some_col"),
      )
  
imports: import numpy
  import pandas
  import pytest
  from pandas.testing import assert_frame_equal
  from sklearn.metrics import mean_absolute_error
  from sklearn.metrics import mean_squared_error
  from testfixtures import LogCapture
  from greykite.common.constants import LOGGER_NAME
  from greykite.common.constants import PREDICTED_COL
  from greykite.common.constants import PREDICTED_LOWER_COL
  from greykite.common.constants import PREDICTED_UPPER_COL
  from greykite.common.constants import TIME_COL
  from greykite.common.constants import VALUE_COL
  from greykite.common.evaluation import r2_null_model_score
  from greykite.sklearn.estimator.base_forecast_estimator import BaseForecastEstimator
  from greykite.sklearn.uncertainty.uncertainty_methods import UncertaintyMethodEnum
label_desc: Use image node_id 11 for calling a global function with example usage: test_populate_uncertainty_params() without return types