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

Method _make_image

Lib/test/test_email/test_email.py:1662–1665  ·  view source on GitHub ↗
(self, ext)

Source from the content-addressed store, hash-verified

1660# Test the basic MIMEImage class
1661class TestMIMEImage(unittest.TestCase):
1662 def _make_image(self, ext):
1663 with openfile(f'python.{ext}', 'rb') as fp:
1664 self._imgdata = fp.read()
1665 self._im = MIMEImage(self._imgdata)
1666
1667 def test_guess_minor_type(self):
1668 for ext, subtype in {

Callers 4

test_guess_minor_typeMethod · 0.95
test_encodingMethod · 0.95
test_checkSetMinorMethod · 0.95
test_add_headerMethod · 0.95

Calls 3

openfileFunction · 0.90
MIMEImageClass · 0.90
readMethod · 0.45

Tested by

no test coverage detected