code: def test_w_parameter_distributions(self) -> None:
      rss = get_robust_search_space()
      # Transform a non-distributional parameter.
      t = CapParameter(
          search_space=rss,
          observations=[],
          config={"z": "2"},
      )
      t.transform_search_space(rss)
      # pyre-fixme[16]: Optional type has no attribute `upper`.
      self.assertEqual(rss.parameters.get("z").upper, 2)
      # Error with distributional parameter.
      t = CapParameter(
          search_space=rss,
          observations=[],
          config={"x": "2"},
      )
      with self.assertRaisesRegex(
          UnsupportedError, "transform is not supported"
      ):
          t.transform_search_space(rss)
  
file_path: Ax/ax/modelbridge/transforms/tests/test_cap_parameter_transform.py
imports: from ax.core.parameter import ChoiceParameter, ParameterType, RangeParameter
  from ax.core.search_space import SearchSpace
  from ax.exceptions.core import UnsupportedError
  from ax.modelbridge.transforms.cap_parameter import CapParameter
  from ax.utils.common.testutils import TestCase
  from ax.utils.testing.core_stubs import get_robust_search_space
label_desc: Use image node_id 3 for calling the CapParameterTest obj's underlying member method code with example usage: obj.test_w_parameter_distributions() without return types