code: def test_process(self):
      root = Metric("test")
      root.process = Mock(return_value="test")
      leaf1 = Metric("test")
      leaf1.process = Mock(return_value={"test": 10})
      leaf2 = Metric("test")
      leaf2.process = Mock(return_value=None)
  
      tree = MetricTree(root)
      tree.add_child(leaf1)
      tree.add_child(leaf2)
  
      self.assertTrue(tree.process("args") == {"test": 10})
  
      root.process.assert_called_once_with("args")
      leaf1.process.assert_called_once_with("test")
      leaf2.process.assert_called_once_with("test")
  
imports: import unittest
  from mock import Mock
  from torchbearer.metrics import MetricList, Metric, MetricTree, AdvancedMetric
label_desc: Use image node_id 2 for calling the TestMetricTree obj's underlying member method code with example usage: obj.test_process() without return types