code: def test_setattribute(worker, guest_client):
      root_domain_client = worker.root_client
  
      private_data, mock_data = (
          np.array([[1.0, 2.0, 3.0], [4.0, 5.0, 6.0]]),
          np.array([[1.0, 1.0, 1.0], [1.0, 1.0, 1.0]]),
      )
  
      obj = TwinObject(private_obj=private_data, mock_obj=mock_data)
  
      assert private_data.dtype != np.int32
  
      obj_pointer = root_domain_client.api.services.action.set(obj)
      obj_pointer = guest_client.api.services.action.get_pointer(
          obj_pointer.id
      )
  
      original_id = obj_pointer.id
  
      # note that this messes up the data and the shape of the array
      obj_pointer.dtype = np.int32
  
      # local object is updated
      assert obj_pointer.id.id in worker.action_store.data
      assert obj_pointer.id != original_id
  
      res = root_domain_client.api.services.action.get(obj_pointer.id)
  
      # check if updated
      assert res.dtype == np.int32
  
      private_data.dtype = np.int32
      mock_data.dtype = np.int32
  
      assert (res == private_data).all()
      assert (obj_pointer.syft_action_data == mock_data).all()
      assert not (obj_pointer.syft_action_data == private_data).all()
  
file_path: PySyft/packages/syft/tests/syft/eager_test.py
imports: import numpy
  from syft.service.action.action_object import ActionObject
  from syft.service.action.plan import planify
  from syft.types.twin_object import TwinObject
label_desc: Use image node_id 5 for calling a global function with example usage: test_setattribute(worker, guest_client) without return types