source: products/quintagroup.pfg.captcha/trunk/quintagroup/pfg/captcha/tests.py @ 2096

Last change on this file since 2096 was 2096, checked in by mylan, 14 years ago

#174: added tests bases

  • Property svn:eol-style set to native
File size: 834 bytes
Line 
1import re
2import unittest
3
4from Products.Five import zcml
5from Products.Five import fiveconfigure
6from Testing import ZopeTestCase as ztc
7from Products.PloneTestCase.layer import onsetup
8from Products.PloneTestCase import PloneTestCase as ptc
9
10PRODUCTS = [
11    'Products.PloneFormGen',
12    'quintagroup.captcha.core',
13    'quintagroup.pfg.captcha',
14]
15PROFILES = [p+':default' for p in PRODUCTS]
16
17@onsetup
18def setup_product():
19    fiveconfigure.debug_mode = True
20    import quintagroup.pfg.captcha
21    zcml.load_config('configure.zcml', quintagroup.pfg.captcha)
22    fiveconfigure.debug_mode = False
23    ztc.installPackage('quintagroup.pfg.captcha')
24    ztc.installPackage('quintagroup.captcha.core')
25
26setup_product()
27ptc.setupPloneSite(extension_profiles=PROFILES)
28
29
30def test_suite():
31    suite = unittest.TestSuite()
32    return suite
Note: See TracBrowser for help on using the repository browser.