MediaWiki  1.28.0
ParserTestResult Class Reference

Represent the result of a parser test. More...

Public Member Functions

 __construct ($test, $expected, $actual)
 
 getDescription ()
 
 isSuccess ()
 Whether the test passed. More...
 

Public Attributes

 $actual
 Actual text rendered. More...
 
 $expected
 Text that was expected. More...
 
 $test
 The test info array. More...
 

Detailed Description

Represent the result of a parser test.

Since
1.22

Definition at line 14 of file ParserTestResult.php.

Constructor & Destructor Documentation

ParserTestResult::__construct (   $test,
  $expected,
  $actual 
)
Parameters
array$testThe test info array from TestIterator
string$expectedThe normalized expected output
string$actualThe actual output

Definition at line 27 of file ParserTestResult.php.

References $actual, $expected, and $test.

Member Function Documentation

ParserTestResult::getDescription ( )

Definition at line 41 of file ParserTestResult.php.

Referenced by ParserTestPrinter\showFailure().

ParserTestResult::isSuccess ( )

Whether the test passed.

Returns
bool

Definition at line 37 of file ParserTestResult.php.

References $actual.

Referenced by DbTestPreviewer\record(), DbTestRecorder\record(), and ParserTestPrinter\record().

Member Data Documentation

ParserTestResult::$actual

Actual text rendered.

Definition at line 20 of file ParserTestResult.php.

Referenced by __construct(), and isSuccess().

ParserTestResult::$expected

Text that was expected.

Definition at line 18 of file ParserTestResult.php.

Referenced by __construct().

ParserTestResult::$test

The test info array.

Definition at line 16 of file ParserTestResult.php.

Referenced by __construct().


The documentation for this class was generated from the following file: