import textwrap


def text_wrapper(text, prefix, separator=''):
    """Wrap text.

    Parameters:
    ----------
    text : {str}
        Text to be warped
    prefix : {str}
        Defines a name of the program to be used as a prefix
        for every line of text
    separator : {str}, optional
        Defines the text inserted between prefix and text
    Returns
    -------
    list
        Returns a list of strings (lines).

    """
    pkg_prefix = prefix + separator
    # empty lines need a special care
    if text != '':
        text_wrapper = textwrap.TextWrapper(
            width=79,
            initial_indent=pkg_prefix,
            subsequent_indent=pkg_prefix)
        warped_text = textwrap.dedent(text)
        warped_text = text_wrapper.wrap(warped_text)
        return warped_text
    else:
        # single line doesn't need trailing spaces
        warped_text = pkg_prefix.rstrip()
        # ensure to always return list, not string
        return warped_text.split()