Merge "jquery.accessKeyLabel: make modifier info public"
[lhc/web/wiklou.git] / tests / phpunit / includes / utils / BatchRowUpdateTest.php
index 082ac82..61d9a70 100644 (file)
@@ -221,7 +221,6 @@ class BatchRowUpdateTest extends MediaWikiTestCase {
                return call_user_func_array( array( $this, 'onConsecutiveCalls' ), $retvals );
        }
 
-
        protected function genSelectResult( $batchSize, $numRows, $rowGenerator ) {
                $res = array();
                for ( $i = 0; $i < $numRows; $i += $batchSize ) {
@@ -238,12 +237,16 @@ class BatchRowUpdateTest extends MediaWikiTestCase {
        protected function mockDb() {
                // Cant mock from DatabaseType or DatabaseBase, they dont
                // have the full gamut of methods
+               // FIXME: the constructor normally sets mAtomicLevels and mSrvCache
                $databaseMysql = $this->getMockBuilder( 'DatabaseMysql' )
                        ->disableOriginalConstructor()
                        ->getMock();
                $databaseMysql->expects( $this->any() )
                        ->method( 'isOpen' )
                        ->will( $this->returnValue( true ) );
+               $databaseMysql->expects( $this->any() )
+                       ->method( 'getApproximateLagStatus' )
+                       ->will( $this->returnValue( array( 'lag' => 0, 'since' => 0 ) ) );
                return $databaseMysql;
        }
 }