Test whether `url` is absolute url (``http://domain.tld/something``) or
    relative (``../something``).

    Args:
        url (str): Tested string.
        protocol (str, default "http"): Protocol which will be seek at the
                 beginning of the `url`.

    Returns:
        bool: True if url is absolute, False if not.

def is_absolute_url(url, protocol="http"):
    """
    Test whether `url` is absolute url (``http://domain.tld/something``) or
    relative (``../something``).

    Args:
        url (str): Tested string.
        protocol (str, default "http"): Protocol which will be seek at the
                 beginning of the `url`.

    Returns:
        bool: True if url is absolute, False if not.
    """
    if ":" not in url:
        return False

    protocol, rest = url.split(":", 1)

    if protocol.startswith(protocol) and rest.startswith("//"):
        return True

    return False