Ignore:
Timestamp:
Feb 19, 2010 4:53:43 PM (14 years ago)
Author:
mylan
Message:

#140: Fix tests after swith to standard control panel form: added authenticator, changed form fields names

File:
1 edited

Legend:

Unmodified
Added
Removed
  • quintagroup.seoptimizer/branches/refactoring2.3.0/quintagroup/seoptimizer/tests/base.py

    r1779 r1792  
    6666ptc.setupPloneSite() 
    6767 
     68class MixinTestCase: 
    6869 
    69 class TestCase(ptc.PloneTestCase): 
     70    def _getauth(self): 
     71        # Fix authenticator for the form 
     72        import re 
     73 
     74        authenticator = self.portal.restrictedTraverse("@@authenticator") 
     75        html = authenticator.authenticator() 
     76        handle = re.search('value="(.*)"', html).groups()[0] 
     77        return handle 
     78 
     79 
     80 
     81class TestCase(MixinTestCase, ptc.PloneTestCase): 
    7082    """We use this base class for all the tests in this package. If 
    7183    necessary, we can put common utility or setup code in here. This 
     
    7385    """ 
    7486 
    75 class FunctionalTestCase(ptc.FunctionalTestCase): 
     87class FunctionalTestCase(MixinTestCase, ptc.FunctionalTestCase): 
    7688    """We use this class for functional integration tests that use 
    7789    doctest syntax. Again, we can put basic common utility or setup 
Note: See TracChangeset for help on using the changeset viewer.