Back to index

plone3  3.1.7
Classes | Functions
GenericSetup.tests.common Namespace Reference

Classes

class  DOMComparator
class  BaseRegistryTests
class  FilesystemTestBase
class  TarballTester
class  DummyExportContext
class  DummyImportContext
class  SecurityRequestTest

Functions

def _clearTestDirectory
def _makeTestFile
def dummy_handler

Function Documentation

def GenericSetup.tests.common._clearTestDirectory (   root_path) [private]

Definition at line 79 of file common.py.

00079 
00080 def _clearTestDirectory( root_path ):
00081 
00082     if os.path.exists( root_path ):
00083         shutil.rmtree( root_path )

Here is the caller graph for this function:

def GenericSetup.tests.common._makeTestFile (   filename,
  root_path,
  contents 
) [private]

Definition at line 84 of file common.py.

00084 
00085 def _makeTestFile( filename, root_path, contents ):
00086 
00087     path, filename = os.path.split( filename )
00088 
00089     subdir = os.path.join( root_path, path )
00090 
00091     if not os.path.exists( subdir ):
00092         os.makedirs( subdir )
00093 
00094     fqpath = os.path.join( subdir, filename )
00095 
00096     file = open( fqpath, 'wb' )
00097     file.write( contents )
00098     file.close()
00099     return fqpath
00100 

Here is the caller graph for this function:

Definition at line 209 of file common.py.

00209 
00210 def dummy_handler( context ):
00211 
00212     pass
00213 
00214 
# BBB: PAS tests use this