code: def test_RandomState_updates():
      rng = shared(np.random.RandomState(1))
      rng_new = shared(np.random.RandomState(2))
  
      x = pt.random.normal(size=10, rng=rng)
      res = function([], x, updates={rng: rng_new}, mode=numba_mode)()
  
      ref = np.random.RandomState(2).normal(size=10)
      assert np.allclose(res, ref)
  
file_path: pytensor/tests/link/numba/test_random.py
imports: import contextlib
  import numpy
  import pytest
  import scipy.stats
  import pytensor.tensor
  import pytensor.tensor.random.basic
  from pytensor import shared
  from pytensor.compile.function import function
  from pytensor.compile.sharedvalue import SharedVariable
  from pytensor.graph.basic import Constant
  from pytensor.graph.fg import FunctionGraph
  from tests.link.numba.test_basic import compare_numba_and_py, eval_python_only, numba_mode, set_test_value
label_desc: Use image node_id 5 for calling a global function with example usage: test_RandomState_updates() without return types