Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F4075445
MultiTestRecorder.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
MultiTestRecorder.php
View Options
<?php
use
Wikimedia\Parsoid\ParserTests\Test
as
ParserTest
;
use
Wikimedia\Parsoid\ParserTests\TestMode
as
ParserTestMode
;
/**
* This is a TestRecorder representing a collection of other TestRecorders.
* It proxies calls to all constituent objects.
*/
class
MultiTestRecorder
extends
TestRecorder
{
/** @var TestRecorder[] */
private
$recorders
=
[];
public
function
addRecorder
(
TestRecorder
$recorder
)
{
$this
->
recorders
[]
=
$recorder
;
}
private
function
proxy
(
$funcName
,
$args
)
{
foreach
(
$this
->
recorders
as
$recorder
)
{
$recorder
->
$funcName
(
...
$args
);
}
}
public
function
start
()
{
$this
->
proxy
(
__FUNCTION__
,
func_get_args
()
);
}
public
function
startTest
(
ParserTest
$test
,
ParserTestMode
$mode
)
{
$this
->
proxy
(
__FUNCTION__
,
func_get_args
()
);
}
public
function
startSuite
(
string
$path
)
{
$this
->
proxy
(
__FUNCTION__
,
func_get_args
()
);
}
public
function
endSuite
(
string
$path
)
{
$this
->
proxy
(
__FUNCTION__
,
func_get_args
()
);
}
public
function
record
(
ParserTestResult
$result
)
{
$this
->
proxy
(
__FUNCTION__
,
func_get_args
()
);
}
public
function
warning
(
string
$message
)
{
$this
->
proxy
(
__FUNCTION__
,
func_get_args
()
);
}
public
function
skipped
(
ParserTest
$test
,
ParserTestMode
$mode
,
string
$reason
)
{
$this
->
proxy
(
__FUNCTION__
,
func_get_args
()
);
}
public
function
report
()
{
$this
->
proxy
(
__FUNCTION__
,
func_get_args
()
);
}
public
function
end
()
{
$this
->
proxy
(
__FUNCTION__
,
func_get_args
()
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Aug 17 2026, 18:33 (10 w, 1 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
5f/49/4b02eb93e61323b3e39169d34bc5
Default Alt Text
MultiTestRecorder.php (1 KB)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment