def METHOD_NAME(create_outlineexplorer, qtbot):
    """
    Test that clicking on the 'Go to cursor position' button located in the
    toolbar of the outline explorer is working as expected.
    Regression test for spyder-ide/spyder#7729.
    """
    outlineexplorer, _ = create_outlineexplorer('text')
    # Move the mouse cursor in the editor to line 15
    editor = outlineexplorer.treewidget.current_editor
    editor._editor.go_to_line(15)
    assert editor._editor.get_text_line(14) == "    def inner():"
    # Click on the 'Go to cursor position' button of the outline explorer's
    # toolbar :
    assert outlineexplorer.treewidget.currentItem() is None
    qtbot.mouseClick(
        outlineexplorer.get_toolbutton(OutlineExplorerToolbuttons.GoToCursor),
        Qt.LeftButton)
    assert outlineexplorer.treewidget.currentItem().text(0) == 'inner'