Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F2750849
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
Fri, Jul 3, 17:15 (16 h, 33 m)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
68/80/c28c7d79b0b37f3414f6b3918595
Default Alt Text
DumpRevTest.php (769 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment