Assist from 8c9cb701e56226cac43fee2fa24b0d0e586f1733 Change-Id: I47897c499028d9e24c00ad0bc6ba7fd8002d9bc1
19 lines
446 B
PHP
19 lines
446 B
PHP
<?php
|
|
|
|
use MediaWiki\Deferred\TransactionRoundDefiningUpdate;
|
|
|
|
/**
|
|
* @covers \MediaWiki\Deferred\TransactionRoundDefiningUpdate
|
|
*/
|
|
class TransactionRoundDefiningUpdateTest extends MediaWikiUnitTestCase {
|
|
|
|
public function testDoUpdate() {
|
|
$ran = 0;
|
|
$update = new TransactionRoundDefiningUpdate( static function () use ( &$ran ) {
|
|
$ran++;
|
|
} );
|
|
$this->assertSame( 0, $ran );
|
|
$update->doUpdate();
|
|
$this->assertSame( 1, $ran );
|
|
}
|
|
}
|