diff options
author | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-06-15 00:09:26 -0400 |
---|---|---|
committer | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-06-15 00:09:26 -0400 |
commit | 122ff0c664383aff780902d66cb7e990aa8d810b (patch) | |
tree | 7a1b755bbce16f61a0210a7b23c4422ccf8e4195 /tests | |
parent | 8d882f529f564bbb03769e2454a73a01984dc11b (diff) | |
download | cmd2-git-122ff0c664383aff780902d66cb7e990aa8d810b.tar.gz |
Fixing unit tests
Diffstat (limited to 'tests')
-rw-r--r-- | tests/conftest.py | 10 | ||||
-rw-r--r-- | tests/test_cmd2.py | 4 |
2 files changed, 8 insertions, 6 deletions
diff --git a/tests/conftest.py b/tests/conftest.py index 1e124219..d20d060a 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -28,8 +28,8 @@ except ImportError: # Help text for base cmd2.Cmd application BASE_HELP = """Documented commands (type help <topic>): ======================================== -alias help load py quit shell -edit history macro pyscript set shortcuts +alias help load py quit run_script shell +edit history macro pyscript run_pyscript set shortcuts """ # noqa: W291 BASE_HELP_VERBOSE = """ @@ -44,6 +44,8 @@ macro Manage macros py Invoke Python command or shell pyscript Run a Python script file inside the console quit Exit this application +run_pyscript Run a Python script file inside the console +run_script Run commands in script file that is encoded as either ASCII or UTF-8 text set Set a settable parameter or show current settings of parameters shell Execute a command as if at the OS prompt shortcuts List available shortcuts @@ -89,8 +91,8 @@ formatting: SHORTCUTS_TXT = """Shortcuts for other commands: !: shell ?: help -@: load -@@: _relative_load +@: run_script +@@: _relative_run_script """ # Output from the show command with default settings diff --git a/tests/test_cmd2.py b/tests/test_cmd2.py index 72643308..f79eb983 100644 --- a/tests/test_cmd2.py +++ b/tests/test_cmd2.py @@ -1934,8 +1934,8 @@ def test_onecmd_raw_str_quit(outsim_app): def test_get_all_commands(base_app): # Verify that the base app has the expected commands commands = base_app.get_all_commands() - expected_commands = ['_relative_load', 'alias', 'edit', 'eof', 'help', 'history', 'load', 'macro', - 'py', 'pyscript', 'quit', 'set', 'shell', 'shortcuts'] + expected_commands = ['_relative_load', '_relative_run_script', 'alias', 'edit', 'eof', 'help', 'history', 'load', + 'macro', 'py', 'pyscript', 'quit', 'run_pyscript', 'run_script', 'set', 'shell', 'shortcuts'] assert commands == expected_commands def test_get_help_topics(base_app): |