|
Moodle
2.2.1
http://www.collinsharper.com
|


Public Member Functions | |
| WithinMarginExpectation ($value, $margin, $message= '%s') | |
| test ($compare) | |
| testMessage ($compare) | |
| _withinMessage ($compare) | |
| _outsideMessage ($compare) | |
Data Fields | |
| $_upper | |
| $_lower | |
Definition at line 328 of file expectation.php.
| _outsideMessage | ( | $ | compare | ) |
Creates a the message for being within the range.
| mixed | $compare | Value being tested. private |
Definition at line 387 of file expectation.php.

| _withinMessage | ( | $ | compare | ) |
Creates a the message for being within the range.
| mixed | $compare | Value being tested. private |
Definition at line 377 of file expectation.php.

| test | ( | $ | compare | ) |
Tests the expectation. True if it matches the held value.
| mixed | $compare | Comparison value. |
Reimplemented from SimpleExpectation.
Reimplemented in OutsideMarginExpectation.
Definition at line 353 of file expectation.php.

| testMessage | ( | $ | compare | ) |
Returns a human readable test message.
| mixed | $compare | Comparison value. |
Reimplemented from SimpleExpectation.
Reimplemented in OutsideMarginExpectation.
Definition at line 364 of file expectation.php.

| WithinMarginExpectation | ( | $ | value, |
| $ | margin, | ||
| $ | message = '%s' |
||
| ) |
Sets the value to compare against and the fuzziness of the match. Used for comparing floating point values.
| mixed | $value | Test value to match. |
| mixed | $margin | Fuzziness of match. |
| string | $message | Customised message on failure. public |
Definition at line 340 of file expectation.php.


| $_lower |
Definition at line 330 of file expectation.php.
| $_upper |
Definition at line 329 of file expectation.php.