Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(1)  |  Call(0)  |  Derive(0)  |  Import(1)

src/p/r/Products.BastionLedger-4.6.0/Products/BastionLedger/tests/testAttachments.py   Products.BastionLedger(Download)
from unittest import TestSuite, makeSuite
from LedgerTestCase import LedgerTestCase
from Products.BastionLedger.BLAttachmentSupport import ATTACHMENTFOLDER_ID
from DateTime import DateTime
from ZPublisher.HTTPRequest import FileUpload, FieldStorage
 
        self.assertEqual(order.hasAttachments(), True)
        attachment = getattr(getattr(order, ATTACHMENTFOLDER_ID), 'Scan001.PDF')
 
        self.assertEqual(hashlib.sha1(order.attachmentPayload('Scan001.PDF')).hexdigest(),