MCPcopy Create free account
hub / github.com/pexpect/pexpect / test_expect_setecho_off

Method test_expect_setecho_off

tests/test_expect.py:238–249  ·  view source on GitHub ↗

This tests that echo may be toggled off.

(self)

Source from the content-addressed store, hash-verified

236 assert index == 3, (index, p.before, p.after)
237
238 def test_expect_setecho_off(self):
239 '''This tests that echo may be toggled off.
240 '''
241 p = pexpect.spawn('cat', echo=True, timeout=5)
242 try:
243 self._expect_echo_toggle(p)
244 except IOError:
245 if sys.platform.lower().startswith('sunos'):
246 if hasattr(unittest, 'SkipTest'):
247 raise unittest.SkipTest("Not supported on this platform.")
248 return 'skip'
249 raise
250
251 def test_expect_setecho_off_exact(self):
252 p = pexpect.spawn('cat', echo=True, timeout=5)

Callers

nothing calls this directly

Calls 2

_expect_echo_toggleMethod · 0.95
spawnMethod · 0.45

Tested by

no test coverage detected