def set_trace(self):
        import _pytest.config
        frame = sys._getframe().f_back
        if self._pluginmanager is not None:
            capman = self._pluginmanager.getplugin("capturemanager")
            if capman:
                capman.suspendcapture(in_=True)
            tw = _pytest.config.create_terminal_writer(self._config)
            tw.line()
            tw.sep(">", "PDB set_trace (IO-capturing turned off)")
            self._pluginmanager.hook.pytest_enter_pdb(config=self._config)
        pdb.Pdb().set_trace(frame)
Test delete on models with related models. This is a crucial
dataset/ETHPy150Open pytest-dev/pytest/_pytest/pdb.py/pytestPDB.set_trace--crossover with--dataset/ETHPy150Open lsbardel/python-stdnet/tests/all/query/delete.py/TestDeleteScalarFields.__testDeleteRelatedCounting