diff options
Diffstat (limited to 'tests/test_popen_spawn.py')
-rw-r--r-- | tests/test_popen_spawn.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/test_popen_spawn.py b/tests/test_popen_spawn.py index 98046ed..fca7493 100644 --- a/tests/test_popen_spawn.py +++ b/tests/test_popen_spawn.py @@ -125,6 +125,14 @@ class ExpectTestCase (PexpectTestCase.PexpectTestCase): p.expect_exact('def') p.expect(pexpect.EOF) + def test_crlf(self): + p = PopenSpawn('echo alpha beta') + assert p.read() == b'alpha beta' + p.crlf + + def test_crlf_encoding(self): + p = PopenSpawn('echo alpha beta', encoding='utf-8') + assert p.read() == 'alpha beta' + p.crlf + if __name__ == '__main__': unittest.main() |