Skip to content

Commit

Permalink
Merge pull request #5710 from radarhere/selftest
Browse files Browse the repository at this point in the history
Moved _info function into docstring
  • Loading branch information
hugovk committed Sep 13, 2021
2 parents 63c5faa + 84ee93f commit dae542b
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions selftest.py
Expand Up @@ -14,17 +14,13 @@
pass


def _info(im):
im.load()
return im.format, im.mode, im.size


def testimage():
"""
PIL lets you create in-memory images with various pixel types:
>>> from PIL import Image, ImageDraw, ImageFilter, ImageMath
>>> im = Image.new("1", (128, 128)) # monochrome
>>> def _info(im): return (im.format, im.mode, im.size)
>>> _info(im)
(None, '1', (128, 128))
>>> _info(Image.new("L", (128, 128))) # grayscale (luminance)
Expand Down

0 comments on commit dae542b

Please sign in to comment.