Changeset 993 in products


Ignore:
Timestamp:
Apr 10, 2009 10:49:02 AM (11 years ago)
Author:
koval
Message:

captcha key property now is removed on uninstall

Location:
quintagroup.plonecaptchas/trunk/quintagroup/plonecaptchas
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • quintagroup.plonecaptchas/trunk/quintagroup/plonecaptchas/setuphandlers.py

    r964 r993  
    4141    if PROPERTY_SHEET in pp.objectIds(): 
    4242        pp.manage_delObjects(ids=[PROPERTY_SHEET]) 
     43 
     44    # remove captcha key property 
     45    if site.hasProperty(CAPTCHA_KEY): 
     46        site._delProperty(CAPTCHA_KEY) 
  • quintagroup.plonecaptchas/trunk/quintagroup/plonecaptchas/tests.py

    r963 r993  
    159159 
    160160    def testCaptchaKey(self): 
    161         ck = getattr(self.portal, 'captcha_key') 
     161        ck = getattr(self.portal, CAPTCHA_KEY) 
    162162        self.assert_(ck) 
    163163        self.assertEqual(len(ck), 8) 
     164        self.qi.uninstallProducts([PRODUCT_NAME]) 
     165        self.assert_(not self.portal.hasProperty(CAPTCHA_KEY)) 
    164166 
    165167def test_suite(): 
Note: See TracChangeset for help on using the changeset viewer.