code: def test_sampling_shape():
      X = np.arange(-5, 5, 0.1).reshape((-1, 1))
      X_test = np.arange(-5.05, 5.05, 0.1).reshape((-1, 1))
      for shape in (None, (-1, 1)):
          if shape is None:
              y = np.sin(X).flatten()
          else:
              y = np.sin(X).reshape(shape)
  
          seed = 1
          rng = np.random.RandomState(seed)
          for gp in (
              get_gp(
                  n_dimensions=1,
                  seed=seed,
                  noise=1e-10,
                  normalize_y=False,
              ),
              get_gp(
                  n_dimensions=1,
                  seed=seed,
                  noise=1e-10,
                  normalize_y=True,
              ),
          ):
              gp._train(X, y)
              func = gp.sample_functions(X_test=X_test, n_funcs=1)
              assert func.shape == (101, 1)
              func = gp.sample_functions(X_test=X_test, n_funcs=2)
              assert func.shape == (101, 2)
  
imports: from unittest.mock import patch
  import numpy
  import pytest
  import scipy.optimize
  import sklearn.datasets
  import sklearn.model_selection
  from ConfigSpace import CategoricalHyperparameter, ConfigurationSpace, EqualsCondition, UniformFloatHyperparameter
  from smac.model.gaussian_process.gaussian_process import GaussianProcess
  from smac.model.gaussian_process.priors import HorseshoePrior, LogNormalPrior
  from smac.utils.configspace import convert_configurations_to_array
label_desc: Use image node_id 13 for calling a global function with example usage: test_sampling_shape() without return types