diff options
author | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-09-30 16:55:54 -0400 |
---|---|---|
committer | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-09-30 16:55:54 -0400 |
commit | 10ffc07459db9bbbc624905162f7f076cad37b96 (patch) | |
tree | fdbc07ab7a4198703a92b6549c6f51892787944d /tests | |
parent | f07808a8f90bd36f25e40b93a23e8360f9c5e7f6 (diff) | |
download | cmd2-git-10ffc07459db9bbbc624905162f7f076cad37b96.tar.gz |
Simplifying tab completion message printing
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_argparse_completer.py | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/tests/test_argparse_completer.py b/tests/test_argparse_completer.py index 308a4d95..fbb2aeb1 100644 --- a/tests/test_argparse_completer.py +++ b/tests/test_argparse_completer.py @@ -654,7 +654,7 @@ def test_unfinished_flag_error(ac_app, command_and_args, text, is_error, capsys) complete_tester(text, line, begidx, endidx, ac_app) out, err = capsys.readouterr() - assert is_error == all(x in out for x in ["Error:\n", "expected"]) + assert is_error == all(x in out for x in ["Error: argument", "expected"]) def test_completion_items_default_header(ac_app): @@ -709,24 +709,6 @@ def test_autocomp_hint(ac_app, command_and_args, text, has_hint, capsys): assert has_hint == ("Hint:\n" in out) -def test_autocomp_hint_multiple_lines(ac_app, capsys): - text = '' - line = 'hint {}'.format(text) - endidx = len(line) - begidx = endidx - len(text) - - first_match = complete_tester(text, line, begidx, endidx, ac_app) - out, err = capsys.readouterr() - - assert first_match is None - assert out == ''' -Hint: - HINT_POS here is a hint - with new lines - -''' - - def test_autocomp_hint_no_help_text(ac_app, capsys): text = '' line = 'hint foo {}'.format(text) |