Beispiel #1
0
def test_parse_aliases():
    exp = {"x": ["yes", "-1"], "y": ["echo", "no"]}
    s = ("some garbage\n"
         "__XONSH_ALIAS_BEG__\n"
         "alias x='yes -1'\n"
         "alias y='echo    no'\n"
         "__XONSH_ALIAS_END__\n"
         "more filth")
    obs = parse_aliases(s, "bash")
    assert exp == obs
Beispiel #2
0
def test_parse_aliases():
    exp = {'x': ['yes', '-1'], 'y': ['echo', 'no']}
    s = ('some garbage\n'
         '__XONSH_ALIAS_BEG__\n'
         "alias x='yes -1'\n"
         "alias y='echo    no'\n"
         '__XONSH_ALIAS_END__\n'
         'more filth')
    obs = parse_aliases(s)
    assert_equal(exp, obs)
Beispiel #3
0
def test_parse_aliases():
    exp = {'x': ['yes', '-1'], 'y': ['echo', 'no']}
    s = ('some garbage\n'
         '__XONSH_ALIAS_BEG__\n'
         "alias x='yes -1'\n"
         "alias y='echo    no'\n"
         '__XONSH_ALIAS_END__\n'
         'more filth')
    obs = parse_aliases(s)
    assert exp == obs
Beispiel #4
0
def test_parse_aliases():
    exp = {"x": ["yes", "-1"], "y": ["echo", "no"]}
    s = (
        "some garbage\n"
        "__XONSH_ALIAS_BEG__\n"
        "alias x='yes -1'\n"
        "alias y='echo    no'\n"
        "__XONSH_ALIAS_END__\n"
        "more filth"
    )
    obs = parse_aliases(s)
    assert_equal(exp, obs)