MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_pending

Method test_pending

Lib/test/test_ssl.py:1761–1773  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1759 self.assertTrue(bio.eof)
1760
1761 def test_pending(self):
1762 bio = ssl.MemoryBIO()
1763 self.assertEqual(bio.pending, 0)
1764 bio.write(b'foo')
1765 self.assertEqual(bio.pending, 3)
1766 for i in range(3):
1767 bio.read(1)
1768 self.assertEqual(bio.pending, 3-i-1)
1769 for i in range(3):
1770 bio.write(b'x')
1771 self.assertEqual(bio.pending, i+1)
1772 bio.read()
1773 self.assertEqual(bio.pending, 0)
1774
1775 def test_buffer_types(self):
1776 bio = ssl.MemoryBIO()

Callers

nothing calls this directly

Calls 3

assertEqualMethod · 0.45
writeMethod · 0.45
readMethod · 0.45

Tested by

no test coverage detected