示例#1
0
def test_parse_quoted_string_start():
    """
    Test parsing of a "complicated" run command.
    """
    input = 'run -d ubuntu:14.04 /bin/sh -c "w'
    first = DockerCompleter.first_token(input)
    assert first == 'run'
示例#2
0
def test_parse_quoted_string_start():
    """
    Test parsing of a "complicated" run command.
    """
    input = 'run -d ubuntu:14.04 /bin/sh -c "w'
    first = DockerCompleter.first_token(input)
    assert first == 'run'
示例#3
0
def test_parse_quoted_string():
    """
    Test parsing of a "complicated" run command.
    """
    input = ('run -d ubuntu:14.04 /bin/sh -c '
             '"while true; do echo hello world; sleep 1; done"')
    first = DockerCompleter.first_token(input)
    assert first == 'run'
示例#4
0
def test_parse_quoted_string():
    """
    Test parsing of a "complicated" run command.
    """
    input = ('run -d ubuntu:14.04 /bin/sh -c '
             '"while true; do echo hello world; sleep 1; done"')
    first = DockerCompleter.first_token(input)
    assert first == 'run'