Ignore:
Timestamp:
2 Sep 2011, 11:43:39 (13 years ago)
Author:
Henrik Bettermann
Message:

Use w.s. test case for functional tests and remove unneeded code. The 'waeup.sirp.app.applicants logger must be removed before super is called.

Call clearSite in tearDown method if setSite has been used in the setUp method.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.sirp/trunk/src/waeup/sirp/applicants/tests/test_root.py

    r6578 r6658  
    4343
    4444
    45 
    46 
    4745class FakeSite(dict):
    4846    pass
     
    5351
    5452    def setUp(self):
     53        remove_logger('waeup.sirp.app.applicants')
    5554        super(ApplicantsRootTestCase, self).setUp()
    56         remove_logger('waeup.sirp.app.applicants')
    57         self.old_loggers = get_all_loggers()
    5855        # Setup a sample site for each test
    59 
    6056        # Prepopulate the ZODB...
    6157        app = University()
     
    6359        self.app = self.getRootFolder()['app']
    6460        setSite(self.app)
    65 
    6661        self.dc_root = tempfile.mkdtemp()
    6762        app['datacenter'].setStoragePath(self.dc_root)
    68 
    6963        return
    7064
    7165    def tearDown(self):
    7266        super(ApplicantsRootTestCase, self).tearDown()
    73         remove_new_loggers(self.old_loggers)
    7467        shutil.rmtree(self.dc_root)
     68        clearSite()
    7569        return
    7670
Note: See TracChangeset for help on using the changeset viewer.