Home | Trees | Indices | Help |
---|
|
object --+ | extension.Extension --+ | runnable.Runnable --+ | test.Test --+ | FileContentsTest
Check that the contents of a file match the expected value.
A 'FileContentsTest' examines the contents of a file. The test passes if and only if the contents exactly match the expected value.
The path to the file itself is not specified explicitly in the test. Instead, it is taken from a contex property; the name of that variable is specified in the **Path Property** field.
Optionally, the test may specify one or more substitutions. Each substitution consists of a regular expression pattern and a replacement string. Both the actual file contents and the expected file contents are processed with these substitutions, with all pattern matches replaced with the corresponding substitutions, before the comparison is performed.
|
|||
Inherited from Inherited from Inherited from |
|
|||
|
|||
|
|||
Inherited from Inherited from Inherited from Inherited from |
|
|||
arguments = [qm.fields.TextField(name= "path_property", title= A list of the arguments to the extension class. |
|||
Inherited from Inherited from Inherited from Inherited from |
|
|||
Inherited from |
|
Run the test. 'context' -- A 'Context' giving run-time parameters to the test. 'result' -- A 'Result' object. The outcome will be 'Result.PASS' when this method is called. The 'result' may be modified by this method to indicate outcomes other than 'Result.PASS' or to add annotations. This method should not return a value. Derived classes must override this method.
|
Perform substitutions on a body of text. returns -- The string 'text', processed with the substitutions configured for this test instance. |
|
argumentsA list of the arguments to the extension class. Each element of this list should be an instance of 'Field'. The 'Field' instance describes the argument. Derived classes may redefine this class variable. However, derived classes should not explicitly include the arguments from base classes; QMTest will automatically combine all the arguments found throughout the class hierarchy.
|
Home | Trees | Indices | Help |
---|
Generated by Epydoc 3.0.1 on Fri Dec 23 12:30:41 2011 | http://epydoc.sourceforge.net |