Back to index

plone3  3.1.7
Public Member Functions | Public Attributes | Static Private Attributes
CMFPlone.tests.testMembershipTool.TestMethodProtection Class Reference
Inheritance diagram for CMFPlone.tests.testMembershipTool.TestMethodProtection:
Inheritance graph
[legend]
Collaboration diagram for CMFPlone.tests.testMembershipTool.TestMethodProtection:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def afterSetUp
def assertUnprotected
def assertProtected
def setRequestMethod
def getAuthenticator
def setupAuthenticator

Public Attributes

 membership

Static Private Attributes

tuple _unprotected

Detailed Description

Definition at line 556 of file testMembershipTool.py.


Member Function Documentation

Definition at line 566 of file testMembershipTool.py.

00566 
00567     def afterSetUp(self):
00568         self.membership = self.portal.portal_membership

Definition at line 573 of file testMembershipTool.py.

00573 
00574     def assertProtected(self, object, method):
00575         self.logout()
00576         self.assertRaises(Unauthorized, object.restrictedTraverse, method)

Here is the call graph for this function:

Definition at line 569 of file testMembershipTool.py.

00569 
00570     def assertUnprotected(self, object, method):
00571         self.logout()
00572         object.restrictedTraverse(method)

Here is the call graph for this function:

Definition at line 30 of file PloneTestCase.py.

00030 
00031     def getAuthenticator(self):
00032         tag = AuthenticatorView('context', 'request').authenticator()
00033         pattern = '<input .*name="(\w+)".*value="(\w+)"'
00034         return match(pattern, tag).groups()

Here is the call graph for this function:

Here is the caller graph for this function:

def CMFPlone.tests.PloneTestCase.PloneTestCase.setRequestMethod (   self,
  method 
) [inherited]
This is a stub now, but in case you want to try
   something fancy on Your Branch (tm), put it here.

Definition at line 26 of file PloneTestCase.py.

00026 
00027     def setRequestMethod(self, method):
00028         self.app.REQUEST.set('REQUEST_METHOD', method)
00029         self.app.REQUEST.method = method

Here is the caller graph for this function:

Definition at line 35 of file PloneTestCase.py.

00035 
00036     def setupAuthenticator(self):
00037         name, token = self.getAuthenticator()
00038         self.app.REQUEST.form[name] = token
00039 

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Initial value:
(
        'changeMemberPortrait',
        'deletePersonalPortrait',
        'testCurrentPassword',
    )

Definition at line 560 of file testMembershipTool.py.

Definition at line 567 of file testMembershipTool.py.


The documentation for this class was generated from the following file: