code: def test_do_posterior_predictive():
      with pm.Model() as m:
          x = pm.Normal("x", 0, 1)
          y = pm.Normal("y", x, 1)
          z = pm.Normal("z", y + x, 1e-3)
  
      # Dummy posterior
      idata_m = az.from_dict(
          {
              "x": np.full((2, 500), 25),
              "y": np.full((2, 500), np.nan),
              "z": np.full((2, 500), np.nan),
          }
      )
  
      # Replace `y` by a constant `100.0`
      m_do = do(m, {y: 100.0})
      with m_do:
          idata_do = pm.sample_posterior_predictive(
              idata_m, var_names="z"
          )
  
      assert 120 < idata_do.posterior_predictive["z"].mean() < 130
  
imports: import arviz
  import numpy
  import pytest
  from pytensor import config
  import pymc
  from pymc.distributions.transforms import logodds
  from pymc.model.transform.conditioning import change_value_transforms, do, observe, remove_value_transforms
  from pymc.variational.minibatch_rv import create_minibatch_rv
label_desc: Use image node_id 6 for calling a global function with example usage: test_do_posterior_predictive() without return types