Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F4100026
DumpRevTest.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
769 B
Referenced Files
None
Subscribers
None
DumpRevTest.php
View Options
<?php
namespace
MediaWiki\Tests\Maintenance
;
use
DumpRev
;
/**
* @covers \DumpRev
* @group Database
* @author Dreamy Jazz
*/
class
DumpRevTest
extends
MaintenanceBaseTestCase
{
protected
function
getMaintenanceClass
()
{
return
DumpRev
::
class
;
}
public
function
testExecuteForMissingRevisionId
()
{
$this
->
maintenance
->
setArg
(
'rev-id'
,
123
);
$this
->
expectCallToFatalError
();
$this
->
expectOutputRegex
(
'/Row not found/'
);
$this
->
maintenance
->
execute
();
}
public
function
testExecute
()
{
$revId
=
$this
->
editPage
(
$this
->
getNonexistingTestPage
(),
'testing1234'
)->
getNewRevision
()->
getId
();
$this
->
maintenance
->
setArg
(
'rev-id'
,
$revId
);
$this
->
maintenance
->
execute
();
$this
->
expectOutputString
(
"Text length: 11
\n
testing1234
\n
"
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Tue, Aug 18, 16:11 (3 w, 5 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
da/16/f1605ab917c02aee601d4d6ddc9d
Default Alt Text
DumpRevTest.php (769 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment