code: def test_load(self, connection):
      foo, bar, baz = self.tables.foo, self.tables.bar, self.tables.baz
      # TODO: add persistence test also
      connection.execute(foo.insert(), dict(a="not bar", b="baz"))
      connection.execute(foo.insert(), dict(a="also not bar", b="baz"))
      connection.execute(foo.insert(), dict(a="i am bar", b="bar"))
      connection.execute(foo.insert(), dict(a="also bar", b="bar"))
  
      class Foo(ComparableEntity):
          pass
  
      class Bar(Foo):
          pass
  
      class Baz(Foo):
          pass
  
      self.mapper_registry.map_imperatively(
          Foo, foo, polymorphic_on=foo.c.b
      )
  
      self.mapper_registry.map_imperatively(
          Baz,
          baz,
          with_polymorphic=(
              "*",
              foo.join(baz, foo.c.b == "baz").select().subquery("baz"),
          ),
          inherits=Foo,
          inherit_condition=(foo.c.a == baz.c.a),
          inherit_foreign_keys=[baz.c.a],
          polymorphic_identity="baz",
      )
  
      self.mapper_registry.map_imperatively(
          Bar,
          bar,
          with_polymorphic=(
              "*",
              foo.join(bar, foo.c.b == "bar").select().subquery("bar"),
          ),
          inherits=Foo,
          inherit_condition=(foo.c.a == bar.c.a),
          inherit_foreign_keys=[bar.c.a],
          polymorphic_identity="bar",
      )
  
      s = Session(connection)
      eq_(s.query(Bar).all(), [Bar(), Bar()])
  
file_path: sqlalchemy/test/orm/inheritance/test_selects.py
imports: from sqlalchemy import ForeignKey
  from sqlalchemy import Integer
  from sqlalchemy import select
  from sqlalchemy import String
  from sqlalchemy.orm import Session
  from sqlalchemy.testing import eq_
  from sqlalchemy.testing import fixtures
  from sqlalchemy.testing.entities import ComparableEntity
  from sqlalchemy.testing.fixtures import fixture_session
  from sqlalchemy.testing.schema import Column
  from sqlalchemy.testing.schema import Table
label_desc: Use image node_id 2 for calling the InheritingSelectablesTest obj's underlying member method code with example usage: obj.test_load(connection) without return types