Class OutsideMarginExpectation

Description

Test for being outside of a range.

Located in /expectation.php (line 402)

SimpleExpectation
   |
   --WithinMarginExpectation
      |
      --OutsideMarginExpectation
Method Summary
 OutsideMarginExpectation __construct (mixed $value, mixed $margin, [string $message = '%s'])
 boolean test (mixed $compare)
 string testMessage (mixed $compare)
Variables

Inherited Variables

Inherited from SimpleExpectation

SimpleExpectation::$dumper
Methods
Constructor __construct (line 412)

Sets the value to compare against and the fuzziness of the match. Used for comparing floating point values.

  • access: public
OutsideMarginExpectation __construct (mixed $value, mixed $margin, [string $message = '%s'])
  • mixed $value: Test value to not match.
  • mixed $margin: Fuzziness of match.
  • string $message: Customised message on failure.

Redefinition of:
WithinMarginExpectation::__construct()
Sets the value to compare against and the fuzziness of the match. Used for comparing floating point values.
test (line 423)

Tests the expectation. True if it matches the held value.

  • return: True if correct.
  • access: public
boolean test (mixed $compare)
  • mixed $compare: Comparison value.

Redefinition of:
WithinMarginExpectation::test()
Tests the expectation. True if it matches the held value.
testMessage (line 434)

Returns a human readable test message.

  • return: Description of success or failure.
  • access: public
string testMessage (mixed $compare)
  • mixed $compare: Comparison value.

Redefinition of:
WithinMarginExpectation::testMessage()
Returns a human readable test message.

Inherited Methods

Inherited From WithinMarginExpectation

 WithinMarginExpectation::__construct()
 WithinMarginExpectation::outsideMessage()
 WithinMarginExpectation::test()
 WithinMarginExpectation::testMessage()
 WithinMarginExpectation::withinMessage()

Inherited From SimpleExpectation

 SimpleExpectation::__construct()
 SimpleExpectation::getDumper()
 SimpleExpectation::isExpectation()
 SimpleExpectation::overlayMessage()
 SimpleExpectation::test()
 SimpleExpectation::testMessage()

Documentation generated on Sun, 31 Oct 2010 16:31:28 -0500 by phpDocumentor 1.4.3