~widelands-dev/widelands-website/trunk

« back to all changes in this revision

Viewing changes to wlimages/tests.py

  • Committer: Holger Rapp
  • Date: 2012-03-17 16:22:06 UTC
  • Revision ID: sirver@gmx.de-20120317162206-fgttamk22qt1nytj
Let post count be calculated automatically instead of keeping track of it manually. Let's see how this affects performance

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
# we append the parent path to sys.path
16
16
import sys; sys.path.append("..")
17
17
 
18
 
import PIL
 
18
import Image as PIL
19
19
from cStringIO import StringIO
20
20
 
21
21
from django.test import TestCase
35
35
    @staticmethod
36
36
    def _make_new_uploaded_image(name,type="bmp"):
37
37
        sio = StringIO()
38
 
        i = PIL.Image.new("RGB",(4,4))
 
38
        i = PIL.new("RGB",(4,4))
39
39
 
40
40
        i.save(sio,type)
41
41