code: def test_inheritance2(self):
      # This is a case where a class could contain an instance
      # of a subclass, which is ignored.
      class Parent(ReplaceableBase):
          pass
  
      class Main(Configurable):
          parent: Parent
          # Note - no __post__init__
  
      @registry.register
      class Derived(Parent, Main):
          pass
  
      args = get_default_args(Main)
      # Derived has been ignored in processing Main.
      self.assertCountEqual(args.keys(), ["parent_class_type"])
  
      main = Main(**args)
  
      with self.assertRaisesRegex(
          ValueError, "UNDEFAULTED has not been registered."
      ):
          run_auto_creation(main)
  
      main.parent_class_type = "Derived"
      # Illustrates that a dict works fine instead of a DictConfig.
      main.parent_Derived_args = {}
      with self.assertRaises(AttributeError):
          main.parent
      run_auto_creation(main)
      self.assertIsInstance(main.parent, Derived)
  
imports: import pickle
  import textwrap
  import unittest
  from dataclasses import dataclass, field, is_dataclass
  from enum import Enum
  from typing import Any, Dict, List, Optional, Tuple
  from unittest.mock import Mock
  from omegaconf import DictConfig, ListConfig, OmegaConf, ValidationError
  from pytorch3d.implicitron.tools.config import _get_type_to_process, _is_actually_dataclass, _ProcessType, _Registry, Configurable, enable_get_default_args, expand_args_fields, get_default_args, get_default_args_field, registry, remove_unused_components, ReplaceableBase, run_auto_creation
label_desc: Use image node_id 9 for calling the TestConfig obj's underlying member method code with example usage: obj.test_inheritance2() without return types