diff options
author | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-04-10 00:18:26 -0400 |
---|---|---|
committer | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-04-10 00:18:26 -0400 |
commit | 6e56ad2040b20b5a3b62e0f16ae72be7743d667e (patch) | |
tree | 06653e37d49295a6666cdd03716cef39c340dca6 /tests/test_cmd2.py | |
parent | f5c904cda48c03a30b3476f3a40224226391deea (diff) | |
download | cmd2-git-6e56ad2040b20b5a3b62e0f16ae72be7743d667e.tar.gz |
Pyscript now saves command output during the same period that redirection does
Diffstat (limited to 'tests/test_cmd2.py')
-rw-r--r-- | tests/test_cmd2.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/test_cmd2.py b/tests/test_cmd2.py index d33477f2..300e3ed9 100644 --- a/tests/test_cmd2.py +++ b/tests/test_cmd2.py @@ -268,9 +268,8 @@ def test_recursive_pyscript_not_allowed(base_app, request): python_script = os.path.join(test_dir, 'scripts', 'recursive.py') expected = 'Recursively entering interactive Python consoles is not allowed.' - run_cmd(base_app, "pyscript {}".format(python_script)) - err = base_app._last_result.stderr - assert err == expected + out, err = run_cmd(base_app, "pyscript {}".format(python_script)) + assert err[0] == expected def test_pyscript_with_nonexist_file(base_app): python_script = 'does_not_exist.py' |