MCPcopy
hub / github.com/jtesta/ssh-audit / test_line

Method test_line

test/test_buffer.py:88–94  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

86 assert r(src) == dst
87
88 def test_line(self):
89 w = lambda x: self.wbuf().write_line(x).write_flush() # noqa
90 r = lambda x: self.rbuf(x).read_line() # noqa
91 tc = [('example line', '65 78 61 6d 70 6c 65 20 6c 69 6e 65 0d 0a')]
92 for p in tc:
93 assert w(p[0]) == self._b(p[1])
94 assert r(self._b(p[1])) == p[0]
95
96 def test_line_nonutf8(self):
97 r = lambda x: self.rbuf(x).read_line() # noqa

Callers

nothing calls this directly

Calls 4

_bMethod · 0.95
write_flushMethod · 0.80
write_lineMethod · 0.80
read_lineMethod · 0.80

Tested by

no test coverage detected