MediaWiki REL1_27
DbTestPreviewer Class Reference
Inheritance diagram for DbTestPreviewer:
Collaboration diagram for DbTestPreviewer:

Public Member Functions

 __construct ( $parent)
 This should be called before the table prefix is changed.
 
 end ()
 Close the DB connection.
 
 getName ( $test, $subtest)
 
 record ( $test, $subtest, $result)
 Called after each test.
 
 report ()
 Called before finishing the test run.
 
 start ()
 Set up result recording; insert a record for the run with the date and all that fun stuff.
 
- Public Member Functions inherited from TestRecorder
 reportPercentage ( $success, $total)
 

Protected Attributes

 $curRun
 
 $db
 
 $lb
 
 $prevRun
 
 $results
 

Private Member Functions

 getTestStatusInfo ( $testname, $after)
 Returns a string giving information about when a test last had a status change.
 

Additional Inherited Members

- Public Attributes inherited from TestRecorder
 $parent
 
 $term
 

Detailed Description

Definition at line 112 of file testHelpers.inc.

Constructor & Destructor Documentation

◆ __construct()

DbTestPreviewer::__construct (   $parent)

This should be called before the table prefix is changed.

Parameters
TestRecorder$parent

Reimplemented from TestRecorder.

Definition at line 123 of file testHelpers.inc.

References TestRecorder\$parent, DB_MASTER, and wfGetLBFactory().

Member Function Documentation

◆ end()

DbTestPreviewer::end ( )

Close the DB connection.

Reimplemented from TestRecorder.

Reimplemented in DbTestRecorder.

Definition at line 313 of file testHelpers.inc.

◆ getName()

DbTestPreviewer::getName (   $test,
  $subtest 
)

Definition at line 151 of file testHelpers.inc.

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

◆ getTestStatusInfo()

DbTestPreviewer::getTestStatusInfo (   $testname,
  $after 
)
private

Returns a string giving information about when a test last had a status change.

Could help to track down when regressions were introduced, as distinct from tests which have never passed (which are more change requests than regressions).

Parameters
string$testname
string$after
Returns
string

Definition at line 247 of file testHelpers.inc.

References $pre.

Referenced by report().

◆ record()

DbTestPreviewer::record (   $test,
  $subtest,
  $result 
)

Called after each test.

Parameters
string$test
integer$subtest
bool$result

Reimplemented from TestRecorder.

Reimplemented in DbTestRecorder.

Definition at line 159 of file testHelpers.inc.

References getName().

◆ report()

DbTestPreviewer::report ( )

Called before finishing the test run.

Reimplemented from TestRecorder.

Definition at line 164 of file testHelpers.inc.

References $code, $count, $res, as, getTestStatusInfo(), and print.

◆ start()

DbTestPreviewer::start ( )

Set up result recording; insert a record for the run with the date and all that fun stuff.

Reimplemented from TestRecorder.

Reimplemented in DbTestRecorder.

Definition at line 135 of file testHelpers.inc.

References print.

Member Data Documentation

◆ $curRun

DbTestPreviewer::$curRun
protected

Definition at line 115 of file testHelpers.inc.

◆ $db

DbTestPreviewer::$db
protected

Definition at line 114 of file testHelpers.inc.

◆ $lb

DbTestPreviewer::$lb
protected

Definition at line 113 of file testHelpers.inc.

◆ $prevRun

DbTestPreviewer::$prevRun
protected

Definition at line 116 of file testHelpers.inc.

◆ $results

DbTestPreviewer::$results
protected

Definition at line 117 of file testHelpers.inc.


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