MCPcopy Index your code
hub / github.com/python/cpython / test_get_bytes

Method test_get_bytes

Lib/test/test_mailbox.py:271–277  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

269 self._check_sample(self._box.get_message(key1))
270
271 def test_get_bytes(self):
272 # Get bytes representations of messages
273 key0 = self._box.add(self._template % 0)
274 key1 = self._box.add(_sample_message)
275 self.assertEqual(self._box.get_bytes(key0),
276 (self._template % 0).encode('ascii'))
277 self.assertEqual(self._box.get_bytes(key1), _bytes_sample_message)
278
279 def test_get_string(self):
280 # Get string representations of messages

Callers

nothing calls this directly

Calls 4

addMethod · 0.45
assertEqualMethod · 0.45
get_bytesMethod · 0.45
encodeMethod · 0.45

Tested by

no test coverage detected