code: def test_hidden_change(self):
      # test list
      l = [1, 2]
      c = cursor(l)
      c[0] = 100
      l[1] = -1
      l2 = c.build()
      self.assertEqual(
          l2, [100, -1]
      )  # change in l affects l2 (this is expected behavior)
      self.assertEqual(l, [1, -1])
  
      # test regular dict
      d = {"a": 1, "b": 2}
      c = cursor(d)
      c["a"] = 100
      d["b"] = -1
      d2 = c.build()
      self.assertEqual(
          d2, {"a": 100, "b": -1}
      )  # change in d affects d2 (this is expected behavior)
      self.assertEqual(d, {"a": 1, "b": -1})
  
      # test TrainState
      params = {"a": 1, "b": 2}
      state = train_state.TrainState.create(
          apply_fn=lambda x: x,
          params=params,
          tx=optax.adam(1e-3),
      )
      c = cursor(state)
      c.params["a"] = 100
      params["b"] = -1
      state2 = c.build()
      self.assertEqual(
          state2.params, {"a": 100, "b": -1}
      )  # change in state affects state2 (this is expected behavior)
      self.assertEqual(state.params, {"a": 1, "b": -1})
  
imports: import dataclasses
  from typing import Any, NamedTuple
  import jax
  import jax.numpy
  import optax
  from absl.testing import absltest
  import flax
  import flax.linen
  from flax.core import freeze
  from flax.cursor import AccessType, _traverse_tree, cursor
  from flax.errors import CursorFindError, TraverseTreeError
  from flax.training import train_state
label_desc: Use image node_id 9 for calling the CursorTest obj's underlying member method code with example usage: obj.test_hidden_change() without return types