Moodle  2.2.1
http://www.collinsharper.com
SimpleScorer Class Reference
Inheritance diagram for SimpleScorer:

Public Member Functions

 SimpleScorer ()
 makeDry ($is_dry=true)
 shouldInvoke ($test_case_name, $method)
createInvoker (&$invoker)
 getStatus ()
 paintGroupStart ($test_name, $size)
 paintGroupEnd ($test_name)
 paintCaseStart ($test_name)
 paintCaseEnd ($test_name)
 paintMethodStart ($test_name)
 paintMethodEnd ($test_name)
 paintPass ($message)
 paintFail ($message)
 paintError ($message)
 paintException ($exception)
 paintSkip ($message)
 getPassCount ()
 getFailCount ()
 getExceptionCount ()
 paintMessage ($message)
 paintFormattedMessage ($message)
 paintSignal ($type, $payload)

Data Fields

 $_passes
 $_fails
 $_exceptions
 $_is_dry_run

Detailed Description

Definition at line 21 of file scorer.php.


Member Function Documentation

& createInvoker ( &$  invoker)

Can wrap the invoker in preperation for running a test.

Parameters:
SimpleInvoker$invokerIndividual test runner.
Returns:
SimpleInvoker Wrapped test runner. public

Reimplemented in EclipseReporter.

Definition at line 66 of file scorer.php.

Accessor for the number of untrapped errors so far.

Returns:
integer Number of exceptions. public

Definition at line 202 of file scorer.php.

Here is the caller graph for this function:

Accessor for the number of fails so far.

Returns:
integer Number of fails. public

Definition at line 192 of file scorer.php.

Here is the caller graph for this function:

Accessor for the number of passes so far.

Returns:
integer Number of passes. public

Definition at line 183 of file scorer.php.

Here is the caller graph for this function:

getStatus ( )

Accessor for current status. Will be false if there have been any failures or exceptions. Used for command line tools.

Returns:
boolean True if no failures. public

Definition at line 77 of file scorer.php.

makeDry ( is_dry = true)

Signals that the next evaluation will be a dry run. That is, the structure events will be recorded, but no tests will be run.

Parameters:
boolean$is_dryDry run if true. public

Definition at line 45 of file scorer.php.

paintCaseEnd ( test_name)

Paints the end of a test case.

Parameters:
string$test_nameName of test or other label. public

Reimplemented in SimpleReporter, EclipseReporter, and XmlReporter.

Definition at line 114 of file scorer.php.

paintCaseStart ( test_name)

Paints the start of a test case.

Parameters:
string$test_nameName of test or other label. public

Reimplemented in SimpleReporter, WebUnitReporter, EclipseReporter, XmlReporter, and TestDoxReporter.

Definition at line 106 of file scorer.php.

paintError ( message)

Deals with PHP 4 throwing an error.

Parameters:
string$messageText of error formatted by the test case. public

Reimplemented in TextReporter, XmlReporter, HtmlReporter, EclipseReporter, and ExHtmlReporter.

Definition at line 157 of file scorer.php.

paintException ( exception)

Deals with PHP 5 throwing an exception.

Parameters:
Exception$exceptionThe actual exception thrown. public

Reimplemented in TextReporter, WebUnitReporter, XmlReporter, HtmlReporter, EclipseReporter, and ExHtmlReporter.

Definition at line 166 of file scorer.php.

paintFail ( message)

Increments the fail count.

Parameters:
string$messageMessage is ignored. public

Reimplemented in TextReporter, WebUnitReporter, XmlReporter, HtmlReporter, EclipseReporter, and ExHtmlReporter.

Definition at line 147 of file scorer.php.

paintFormattedMessage ( message)

Paints a formatted ASCII message such as a variable dump.

Parameters:
string$messageText to display. public

Reimplemented in TextReporter, XmlReporter, WebUnitReporter, and HtmlReporter.

Definition at line 220 of file scorer.php.

paintGroupEnd ( test_name)

Paints the end of a group test.

Parameters:
string$test_nameName of test or other label. public

Reimplemented in SimpleReporter, EclipseReporter, and XmlReporter.

Definition at line 98 of file scorer.php.

paintGroupStart ( test_name,
size 
)

Paints the start of a group test.

Parameters:
string$test_nameName of test or other label.
integer$sizeNumber of test cases starting. public

Reimplemented in SimpleReporter, EclipseReporter, WebUnitReporter, and XmlReporter.

Definition at line 90 of file scorer.php.

paintMessage ( message)

Paints a simple supplementary message.

Parameters:
string$messageText to display. public

Reimplemented in XmlReporter, and ExHtmlReporter.

Definition at line 211 of file scorer.php.

paintMethodEnd ( test_name)

Paints the end of a test method.

Parameters:
string$test_nameName of test or other label. public

Reimplemented in SimpleReporter, WebUnitReporter, EclipseReporter, and XmlReporter.

Definition at line 130 of file scorer.php.

paintMethodStart ( test_name)

Paints the start of a test method.

Parameters:
string$test_nameName of test or other label. public

Reimplemented in SimpleReporter, WebUnitReporter, EclipseReporter, XmlReporter, and TestDoxReporter.

Definition at line 122 of file scorer.php.

paintPass ( message)

Increments the pass count.

Parameters:
string$messageMessage is ignored. public

Reimplemented in XmlReporter, EclipseReporter, and ExHtmlReporter.

Definition at line 138 of file scorer.php.

paintSignal ( type,
payload 
)

By default just ignores user generated events.

Parameters:
string$typeEvent type as text.
mixed$payloadMessage or object. public

Reimplemented in XmlReporter.

Definition at line 229 of file scorer.php.

paintSkip ( message)

Prints the message for skipping tests.

Parameters:
string$messageText of skip condition. public

Reimplemented in TextReporter, XmlReporter, HtmlReporter, and ExHtmlReporter.

Definition at line 175 of file scorer.php.

shouldInvoke ( test_case_name,
method 
)

The reporter has a veto on what should be run.

Parameters:
string$test_case_namename of test case.
string$methodName of test method. public

Definition at line 55 of file scorer.php.

Starts the test run with no results. public

Definition at line 31 of file scorer.php.

Here is the caller graph for this function:


Field Documentation

$_exceptions

Definition at line 24 of file scorer.php.

$_fails

Definition at line 23 of file scorer.php.

$_is_dry_run

Definition at line 25 of file scorer.php.

$_passes

Definition at line 22 of file scorer.php.


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations