code: def test_pdb_with_caplog_on_pdb_invocation(
      self, pytester: Pytester
  ) -> None:
      p1 = pytester.makepyfile(
          """
              def test_1(capsys, caplog):
                  import logging
                  logging.getLogger(__name__).warning("some_warning")
                  assert 0
          """
      )
      child = pytester.spawn_pytest("--pdb %s" % str(p1))
      child.send("caplog.record_tuples\n")
      child.expect_exact(
          "[('test_pdb_with_caplog_on_pdb_invocation', 30, 'some_warning')]"
      )
      child.sendeof()
      child.read()
      self.flush(child)
  
imports: import os
  import sys
  from typing import List
  import _pytest._code
  import pytest
  from _pytest.debugging import _validate_usepdb_cls
  from _pytest.monkeypatch import MonkeyPatch
  from _pytest.pytester import Pytester
label_desc: Use image node_id 23 for calling the TestPDB obj's underlying member method code with example usage: obj.test_pdb_with_caplog_on_pdb_invocation(pytester) without return types