summaryrefslogtreecommitdiff
path: root/tests/test_cmd2.py
diff options
context:
space:
mode:
authorTodd Leonhardt <todd.leonhardt@gmail.com>2017-06-16 14:52:40 -0400
committerGitHub <noreply@github.com>2017-06-16 14:52:40 -0400
commit1b829f13cfa9460ddb6304d507ea30bfbb31c6e7 (patch)
treec8f391305be310444687401d452ba34583840e45 /tests/test_cmd2.py
parent89f58e23ad5f4db5f3d58a526ba5df5a199516c9 (diff)
parent891ca5c7f6a7a3d94d9ad686fdad1ded80bc336b (diff)
downloadcmd2-git-1b829f13cfa9460ddb6304d507ea30bfbb31c6e7.tar.gz
Merge pull request #134 from python-cmd2/reword_cmdenvironnment
Reword cmdenvironnment
Diffstat (limited to 'tests/test_cmd2.py')
-rw-r--r--tests/test_cmd2.py19
1 files changed, 11 insertions, 8 deletions
diff --git a/tests/test_cmd2.py b/tests/test_cmd2.py
index c38adc5d..15ae6cc2 100644
--- a/tests/test_cmd2.py
+++ b/tests/test_cmd2.py
@@ -222,16 +222,19 @@ def test_base_cmdenvironment(base_app):
out = run_cmd(base_app, 'cmdenvironment')
expected = normalize("""
- Commands are case-sensitive: False
- Commands may be terminated with: [';']
- Command-line arguments allowed: True
- Output redirection and pipes allowed: True
+ Commands are case-sensitive: {}
+ Commands may be terminated with: {}
+ Arguments at invocation allowed: {}
+ Output redirection and pipes allowed: {}
Parsing of @options commands:
- Use POSIX-style argument parser (vs Windows): {}
- Strip Quotes when using Windows-style argument parser: {}
- Use a list of arguments instead of a single argument string: {}
+ Shell lexer mode for command argument splitting: {}
+ Strip Quotes after splitting arguments: {}
+ Argument type: {}
-""".format(cmd2.POSIX_SHLEX, cmd2.STRIP_QUOTES_FOR_NON_POSIX, cmd2.USE_ARG_LIST))
+""".format(not base_app.case_insensitive, base_app.terminators, base_app.allow_cli_args, base_app.allow_redirection,
+ "POSIX" if cmd2.POSIX_SHLEX else "non-POSIX",
+ "True" if cmd2.STRIP_QUOTES_FOR_NON_POSIX and not cmd2.POSIX_SHLEX else "False",
+ "List of argument strings" if cmd2.USE_ARG_LIST else "string of space-separated arguments"))
assert out == expected
def test_base_load(base_app, request):