Ignore:
Timestamp:
Feb 10, 2010 5:33:40 PM (14 years ago)
Author:
mylan
Message:

#133: Added testing bases

File:
1 edited

Legend:

Unmodified
Added
Removed
  • quintagroup.canonicalpath/trunk/quintagroup/canonicalpath/tests.py

    r1697 r1699  
    55from Testing import ZopeTestCase as ztc 
    66 
     7from Products.Five import zcml 
     8from Products.Five import fiveconfigure 
     9from Products.PloneTestCase import PloneTestCase as ptc 
     10from Products.PloneTestCase.layer import PloneSite 
     11ptc.setupPloneSite() 
     12 
     13import quintagroup.canonicalpath 
     14 
     15class TestCase(ptc.PloneTestCase): 
     16    class layer(PloneSite): 
     17        @classmethod 
     18        def setUp(cls): 
     19            fiveconfigure.debug_mode = True 
     20            zcml.load_config('configure.zcml', 
     21                             quintagroup.canonicalpath) 
     22            fiveconfigure.debug_mode = False 
     23 
     24        @classmethod 
     25        def tearDown(cls): 
     26            pass 
     27 
     28 
    729def test_suite(): 
    830    return unittest.TestSuite([ 
    931 
    10         # Unit tests for your API 
    11         doctestunit.DocFileSuite( 
    12             'README.txt', package='quintagroup.canonicalpath', 
    13             setUp=testing.setUp, tearDown=testing.tearDown), 
     32        # Unit tests 
     33        #doctestunit.DocFileSuite( 
     34        #    'README.txt', package='quintagroup.canonicalpath', 
     35        #    setUp=testing.setUp, tearDown=testing.tearDown), 
    1436 
    1537        #doctestunit.DocTestSuite( 
     
    1739        #    setUp=testing.setUp, tearDown=testing.tearDown), 
    1840 
    19         # Integration tests that use ZopeTestCase 
     41 
     42        # Integration tests that use PloneTestCase 
    2043        #ztc.ZopeDocFileSuite( 
    2144        #    'README.txt', package='quintagroup.canonicalpath', 
    22         #    setUp=testing.setUp, tearDown=testing.tearDown), 
     45        #    test_class=TestCase), 
    2346 
    2447        #ztc.FunctionalDocFileSuite( 
    25         #    'browser.txt', package='quintagroup.canonicalpath'), 
     48        #    'browser.txt', package='quintagroup.canonicalpath', 
     49        #    test_class=TestCase), 
    2650 
    2751        ]) 
Note: See TracChangeset for help on using the changeset viewer.