| [ Index ] |
|
Code source de PRADO 3.0.6 |
[Code source] [Imprimer] [Statistiques]
base include file for SimpleTest
| Version: | $Id: expectation.php 1526 2006-11-28 23:34:00Z wei $ |
| Poids: | 720 lignes (26 kb) |
| Inclus ou requis: | 0 fois |
| Référencé: | 0 fois |
| Nécessite: | 0 fichiers |
SimpleExpectation:: (6 méthodes):
SimpleExpectation()
test()
testMessage()
overlayMessage()
_getDumper()
isExpectation()
EqualExpectation:: (4 méthodes):
EqualExpectation()
test()
testMessage()
_getValue()
NotEqualExpectation:: (3 méthodes):
NotEqualExpectation()
test()
testMessage()
WithinMarginExpectation:: (5 méthodes):
WithinMarginExpectation()
test()
testMessage()
_withinMessage()
_outsideMessage()
OutsideMarginExpectation:: (3 méthodes):
OutsideMarginExpectation()
test()
testMessage()
IdenticalExpectation:: (3 méthodes):
IdenticalExpectation()
test()
testMessage()
NotIdenticalExpectation:: (3 méthodes):
NotIdenticalExpectation()
test()
testMessage()
PatternExpectation:: (5 méthodes):
PatternExpectation()
_getPattern()
test()
testMessage()
_describePatternMatch()
WantedPatternExpectation:: (0 méthodes):
NoPatternExpectation:: (3 méthodes):
NoPatternExpectation()
test()
testMessage()
UnwantedPatternExpectation:: (0 méthodes):
IsAExpectation:: (5 méthodes):
IsAExpectation()
_getType()
test()
_canonicalType()
testMessage()
NotAExpectation:: (3 méthodes):
NotAExpectation()
test()
testMessage()
MethodExistsExpectation:: (3 méthodes):
MethodExistsExpectation()
test()
testMessage()
Classe: SimpleExpectation - X-Ref
Assertion that can display failure information.| SimpleExpectation($message = '%s') X-Ref |
| Creates a dumper for displaying values and sets the test message. param: string $message Customised message on failure. |
| test($compare) X-Ref |
| Tests the expectation. True if correct. param: mixed $compare Comparison value. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
| overlayMessage($compare) X-Ref |
| Overlays the generated message onto the stored user message. An additional message can be interjected. param: mixed $compare Comparison value. return: string Description of success |
| _getDumper() X-Ref |
| Accessor for the dumper. return: SimpleDumper Current value dumper. |
| isExpectation($expectation) X-Ref |
| Test to see if a value is an expectation object. A useful utility method. param: mixed $expectation Hopefully an Epectation return: boolean True if descended from |
Classe: EqualExpectation - X-Ref
Test for equality.| EqualExpectation($value, $message = '%s') X-Ref |
| Sets the value to compare against. param: mixed $value Test value to match. param: string $message Customised message on failure. |
| test($compare) X-Ref |
| Tests the expectation. True if it matches the held value. param: mixed $compare Comparison value. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
| _getValue() X-Ref |
| Accessor for comparison value. return: mixed Held value to compare with. |
Classe: NotEqualExpectation - X-Ref
Test for inequality.| NotEqualExpectation($value, $message = '%s') X-Ref |
| Sets the value to compare against. param: mixed $value Test value to match. param: string $message Customised message on failure. |
| test($compare) X-Ref |
| Tests the expectation. True if it differs from the held value. param: mixed $compare Comparison value. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
Classe: WithinMarginExpectation - X-Ref
Test for being within a range.| WithinMarginExpectation($value, $margin, $message = '%s') X-Ref |
| Sets the value to compare against and the fuzziness of the match. Used for comparing floating point values. param: mixed $value Test value to match. param: mixed $margin Fuzziness of match. param: string $message Customised message on failure. |
| test($compare) X-Ref |
| Tests the expectation. True if it matches the held value. param: mixed $compare Comparison value. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
| _withinMessage($compare) X-Ref |
| Creates a the message for being within the range. param: mixed $compare Value being tested. |
| _outsideMessage($compare) X-Ref |
| Creates a the message for being within the range. param: mixed $compare Value being tested. |
Classe: OutsideMarginExpectation - X-Ref
Test for being outside of a range.| OutsideMarginExpectation($value, $margin, $message = '%s') X-Ref |
| Sets the value to compare against and the fuzziness of the match. Used for comparing floating point values. param: mixed $value Test value to not match. param: mixed $margin Fuzziness of match. param: string $message Customised message on failure. |
| test($compare) X-Ref |
| Tests the expectation. True if it matches the held value. param: mixed $compare Comparison value. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
Classe: IdenticalExpectation - X-Ref
Test for identity.| IdenticalExpectation($value, $message = '%s') X-Ref |
| Sets the value to compare against. param: mixed $value Test value to match. param: string $message Customised message on failure. |
| test($compare) X-Ref |
| Tests the expectation. True if it exactly matches the held value. param: mixed $compare Comparison value. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
Classe: NotIdenticalExpectation - X-Ref
Test for non-identity.| NotIdenticalExpectation($value, $message = '%s') X-Ref |
| Sets the value to compare against. param: mixed $value Test value to match. param: string $message Customised message on failure. |
| test($compare) X-Ref |
| Tests the expectation. True if it differs from the held value. param: mixed $compare Comparison value. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
Classe: PatternExpectation - X-Ref
Test for a pattern using Perl regex rules.| PatternExpectation($pattern, $message = '%s') X-Ref |
| Sets the value to compare against. param: string $pattern Pattern to search for. param: string $message Customised message on failure. |
| _getPattern() X-Ref |
| Accessor for the pattern. return: string Perl regex as string. |
| test($compare) X-Ref |
| Tests the expectation. True if the Perl regex matches the comparison value. param: string $compare Comparison value. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
| _describePatternMatch($pattern, $subject) X-Ref |
| Describes a pattern match including the string found and it's position. param: string $pattern Regex to match against. param: string $subject Subject to search. |
Classe: WantedPatternExpectation - X-Ref
Classe: NoPatternExpectation - X-Ref
Fail if a pattern is detected within the| NoPatternExpectation($pattern, $message = '%s') X-Ref |
| Sets the reject pattern param: string $pattern Pattern to search for. param: string $message Customised message on failure. |
| test($compare) X-Ref |
| Tests the expectation. False if the Perl regex matches the comparison value. param: string $compare Comparison value. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: string $compare Comparison value. return: string Description of success |
Classe: UnwantedPatternExpectation - X-Ref
Classe: IsAExpectation - X-Ref
Tests either type or class name if it's an object.| IsAExpectation($type, $message = '%s') X-Ref |
| Sets the type to compare with. param: string $type Type or class name. param: string $message Customised message on failure. |
| _getType() X-Ref |
| Accessor for type to check against. return: string Type or class name. |
| test($compare) X-Ref |
| Tests the expectation. True if the type or class matches the string value. param: string $compare Comparison value. return: boolean True if correct. |
| _canonicalType($type) X-Ref |
| Coerces type name into a gettype() match. param: string $type User type. return: string Simpler type. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
Classe: NotAExpectation - X-Ref
Tests either type or class name if it's an object.| NotAExpectation($type, $message = '%s') X-Ref |
| Sets the type to compare with. param: string $type Type or class name. param: string $message Customised message on failure. |
| test($compare) X-Ref |
| Tests the expectation. False if the type or class matches the string value. param: string $compare Comparison value. return: boolean True if different. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
Classe: MethodExistsExpectation - X-Ref
Tests for existance of a method in an object| MethodExistsExpectation($method, $message = '%s') X-Ref |
| Sets the value to compare against. param: string $method Method to check. param: string $message Customised message on failure. return: void |
| test($compare) X-Ref |
| Tests the expectation. True if the method exists in the test object. param: string $compare Comparison method name. return: boolean True if correct. |
| testMessage($compare) X-Ref |
| Returns a human readable test message. param: mixed $compare Comparison value. return: string Description of success |
| Généré le : Sun Feb 25 21:07:04 2007 | par Balluche grâce à PHPXref 0.7 |