code: def test_add_def(self):
      self.assertFalse("test_func" in self.cs)
  
      @self.cs.add_def("test_func", "Test function")
      def test_func():
          return 123
  
      self.assertTrue("test_func" in self.cs)
  
      self.assertEqual(len(self.cs), 1)
      self.assertEqual(list(self.cs), [("test_func", test_func)])
  
      self.assertEqual(self.cs.test_func, test_func)
      self.assertEqual(self.cs["test_func"], test_func)
  
      # try adding the same function again
      self.cs.add_def(
          "test_func", "Test function but with new description"
      )(test_func)
  
      self.assertEqual(len(self.cs), 1)
      self.assertEqual(self.cs.test_func, test_func)
  
file_path: MONAI/tests/test_component_store.py
imports: from __future__ import annotations
  import unittest
  from monai.utils import ComponentStore
label_desc: Use image node_id 5 for calling the TestComponentStore obj's underlying member method code with example usage: obj.test_add_def() and returns: int