def METHOD_NAME(
        self,
        webbrowser: bool = True,
        sync: bool = False,
        globals: Dict[str, Any] | None = None,
) -> Future | None:  # pragma: no cover
    """
    This method pauses the current test by starting an rlpython shell and
    starts a webbrowser that points to the currently running test server.
    The test continues when the rlpython shell is exited.
    Async Example:
        async def test_my_feature(lona_app_context):
            context = await lona_app_context(setup_app)
            await context.debug_interactive(locals=locals())
    Sync Example:
        async def test_my_feature(lona_app_context):
            context = await lona_app_context(setup_app)
            def run_test():
                context.debug_interactive(
                    sync=True,
                    globals=locals(),
                )
            context.event_loop.run_in_executor(None, run_test)
    :webbrowser: (bool) start a webbrowser that points to the test server
    :sync:       (bool) run blocking in the current thread
    :globals:    (dict|None) variable overrides for the rlpython shell
    """
    capmanager = self.pytestconfig.pluginmanager.getplugin(
        'capturemanager',
    )
    def _debug_interactive():
        try:
            # disable stdin and stdout capturing temporarily
            capmanager.suspend_global_capture(in_=True)
            # start browser
            if webbrowser:
                os.environ['DISPLAY'] = ':0'
                _webbrowser.open(self.make_url())
            # embed shell
            _globals = globals or {}
            _globals = {
                'server': self.server,
                'lona_context': self,
                **_globals,
            }
            embed_shell(
                server=self.server,
                globals=_globals,
            )
        finally:
            capmanager.resume_global_capture()
    if sync:
        _debug_interactive()
        return None
    return self.event_loop.run_in_executor(None, _debug_interactive)