Пример #1
0
 def work(self, img_url):
     """
     Grab an image and create a b64 encoded thumbnail.
     """
     return image.b64_thumbnail_from_url(img_url)
Пример #2
0
 def test_png_mimetype(self):
     b64 = image.b64_thumbnail_from_url(png_url)
     data = b64.split(';')[0]
     assert ('png' in data)
Пример #3
0
 def work(self, img_url):
     """
     Grab an image and create a b64 encoded thumbnail.
     """
     return image.b64_thumbnail_from_url(img_url)
Пример #4
0
 def test_gif(self):
     b64 = image.b64_thumbnail_from_url(gif_url)
     data = b64.split(';')[0]
     assert ('gif' in data)
Пример #5
0
 def test_jpeg(self):
     b64 = image.b64_thumbnail_from_url(jpeg_url)
     data = b64.split(';')[0]
     assert ('jpeg' in data)
Пример #6
0
 def test_png_mimetype(self):
     b64 = image.b64_thumbnail_from_url(png_url)
     data = b64.split(';')[0]
     assert('png' in data)
Пример #7
0
 def test_gif(self):
     b64 = image.b64_thumbnail_from_url(gif_url)
     data = b64.split(';')[0]
     assert('gif' in data)
Пример #8
0
 def test_jpeg(self):
     b64 = image.b64_thumbnail_from_url(jpeg_url)
     data = b64.split(';')[0]
     assert('jpeg' in data)