Back to index

plone3  3.1.7
Classes | Functions | Variables
ATContentTypes.tests.test_atimage Namespace Reference

Classes

class  TestSiteATImage
class  TestATImageFields
class  TestATImageFunctional

Functions

def loadImage
def editATCT
def test_suite

Variables

string __author__ = 'Christian Heimes <tiran@cheimes.de>'
string __docformat__ = 'restructuredtext'
tuple TEST_EXIF_ERROR = loadImage('canoneye.jpg')
tuple TEST_GIF = loadImage('test.gif')
tuple TEST_GIF_LEN = len(TEST_GIF)
tuple TEST_DIV_ERROR = loadImage('divisionerror.jpg')
tuple TEST_JPEG_FILE = open(os.path.join(PACKAGE_HOME, 'input', 'canoneye.jpg'), 'rb')
tuple TEST_JPEG = loadImage('canoneye.jpg')
tuple TEST_JPEG_LEN = len(TEST_JPEG)
list tests = []

Function Documentation

Definition at line 75 of file test_atimage.py.

00075 
00076 def editATCT(obj):
00077     obj.setImage(TEST_GIF, content_type="image/gif")
00078     dcEdit(obj)

Here is the call graph for this function:

Here is the caller graph for this function:

def ATContentTypes.tests.test_atimage.loadImage (   name,
  size = 0 
)
Load image from testing directory

Definition at line 56 of file test_atimage.py.

00056 
00057 def loadImage(name, size=0):
00058     """Load image from testing directory
00059     """
00060     path = os.path.join(PACKAGE_HOME, 'input', name)
00061     fd = open(path, 'rb')
00062     data = fd.read()
00063     fd.close()
00064     return data

Definition at line 313 of file test_atimage.py.

00313 
00314 def test_suite():
00315     suite = unittest.TestSuite()
00316     for test in tests:
00317         suite.addTest(unittest.makeSuite(test))
00318     return suite

Variable Documentation

string ATContentTypes.tests.test_atimage.__author__ = 'Christian Heimes <tiran@cheimes.de>'

Definition at line 22 of file test_atimage.py.

Definition at line 23 of file test_atimage.py.

Definition at line 68 of file test_atimage.py.

Definition at line 65 of file test_atimage.py.

Definition at line 66 of file test_atimage.py.

Definition at line 67 of file test_atimage.py.

Definition at line 72 of file test_atimage.py.

tuple ATContentTypes.tests.test_atimage.TEST_JPEG_FILE = open(os.path.join(PACKAGE_HOME, 'input', 'canoneye.jpg'), 'rb')

Definition at line 69 of file test_atimage.py.

Definition at line 73 of file test_atimage.py.

Definition at line 79 of file test_atimage.py.