(path)
Test whether a path is a mount point (a drive root, the root of a
    share, or a mounted volume)
Test whether a path is a mount point (a drive root, the root of a
    share, or a mounted volume)
Test whether a path is a mount point ( a drive root the root of a share or a mounted volume )
def ismount(path):
    """Test whether a path is a mount point (a drive root, the root of a
    share, or a mounted volume)"""
    path = os.fspath(path)
    seps = _get_bothseps(path)
    path = abspath(path)
    root, rest = splitdrive(path)
    if root and root[0] in seps:
        return (not rest) or (rest in seps)
    if rest in seps:
        return True

    if _getvolumepathname:
        return path.rstrip(seps) == _getvolumepathname(path).rstrip(seps)
    else:
        return False
def ismount ( path ) : path = os . fspath ( path ) seps = _get_bothseps ( path ) path = abspath ( path ) root , rest = splitdrive ( path ) if root and root [ 0 ] in seps : return ( not rest ) or ( rest in seps ) if rest in seps : return True if _getvolumepathname : return path . rstrip ( seps ) == _getvolumepathname ( path ) . rstrip ( seps ) else : return False