summaryrefslogtreecommitdiff
path: root/tests/test_utils.py
diff options
context:
space:
mode:
authorEric Lin <anselor@gmail.com>2020-09-08 16:01:04 -0400
committerEric Lin <anselor@gmail.com>2020-09-11 01:44:29 -0400
commitc75f92cf280ea45aefd203e0c2554dd84765a52e (patch)
tree7f198ddcb29d11e0cb70839671e85e1a5c640a19 /tests/test_utils.py
parent49f4f7e425e06fcafc0bda7b26984894bc82a30e (diff)
downloadcmd2-git-enh_default_categories.tar.gz
Minor type hinting fixes.enh_default_categories
Diffstat (limited to 'tests/test_utils.py')
-rw-r--r--tests/test_utils.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/test_utils.py b/tests/test_utils.py
index 27bf4743..2c94466c 100644
--- a/tests/test_utils.py
+++ b/tests/test_utils.py
@@ -154,6 +154,13 @@ def test_stdsim_read(stdout_sim):
assert stdout_sim.read() == my_str
assert stdout_sim.getvalue() == ''
+ stdout_sim.write(my_str)
+
+ assert stdout_sim.getvalue() == my_str
+ assert stdout_sim.read(2) == my_str[:2]
+ assert stdout_sim.getvalue() == my_str[2:]
+
+
def test_stdsim_read_bytes(stdout_sim):
b_str = b'Hello World'
stdout_sim.buffer.write(b_str)