Minor changes in the test system; XmlUnmarshaller can unmarshall XML content from a string, file handler of file path; any Appy object now has a method 'getField(name)' that returns a given field (=Appy type); bugfix while counting number of tests found in a gen-application.
This commit is contained in:
parent
2c6392aa92
commit
a8366379dd
5 changed files with 23 additions and 8 deletions
|
@ -5,7 +5,7 @@ import os, os.path, sys
|
|||
class TestMixin:
|
||||
'''This class is mixed in with any PloneTestCase.'''
|
||||
def createUser(self, userId, roles):
|
||||
'''Creates a user p_name p_with some p_roles.'''
|
||||
'''Creates a user with id p_userId with some p_roles.'''
|
||||
pms = self.portal.portal_membership
|
||||
pms.addMember(userId, 'password', [], [])
|
||||
self.setRoles(roles, name=userId)
|
||||
|
@ -16,7 +16,7 @@ class TestMixin:
|
|||
self.login(userId)
|
||||
|
||||
def getNonEmptySubModules(self, moduleName):
|
||||
'''Returns the list fo sub-modules of p_app that are non-empty.'''
|
||||
'''Returns the list of sub-modules of p_app that are non-empty.'''
|
||||
res = []
|
||||
try:
|
||||
exec 'import %s' % moduleName
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue