aboutsummaryrefslogtreecommitdiffstats
path: root/tests/phpunit/includes/utils/BatchRowUpdateTest.php
diff options
context:
space:
mode:
authorAaron Schulz <aschulz@wikimedia.org>2016-09-26 15:40:07 -0700
committerAaron Schulz <aschulz@wikimedia.org>2016-09-27 04:20:03 +0000
commit5bbac35ed1ce873f9e78dcbadf28b763afe4e9d1 (patch)
tree9d0ba49ca0694d0714dd17248ad0e4a71082b7f4 /tests/phpunit/includes/utils/BatchRowUpdateTest.php
parent1deee13f805bec30b38730eae0bb525afb42c12d (diff)
downloadmediawikicore-5bbac35ed1ce873f9e78dcbadf28b763afe4e9d1.tar.gz
mediawikicore-5bbac35ed1ce873f9e78dcbadf28b763afe4e9d1.zip
Replace DatabaseBase:: with Database:: and update type hints
Change-Id: I3919b04eb2de4fa0bf8a02239fb5bbf17d347511
Diffstat (limited to 'tests/phpunit/includes/utils/BatchRowUpdateTest.php')
-rw-r--r--tests/phpunit/includes/utils/BatchRowUpdateTest.php9
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/phpunit/includes/utils/BatchRowUpdateTest.php b/tests/phpunit/includes/utils/BatchRowUpdateTest.php
index 560b6d2fb65d..ce6894e04b9a 100644
--- a/tests/phpunit/includes/utils/BatchRowUpdateTest.php
+++ b/tests/phpunit/includes/utils/BatchRowUpdateTest.php
@@ -129,7 +129,7 @@ class BatchRowUpdateTest extends MediaWikiTestCase {
$db = $this->mockDb();
$db->expects( $this->once() )
->method( 'select' )
- // only testing second parameter of DatabaseBase::select
+ // only testing second parameter of Database::select
->with( 'some_table', $columns )
->will( $this->returnValue( new ArrayIterator( [] ) ) );
@@ -164,7 +164,7 @@ class BatchRowUpdateTest extends MediaWikiTestCase {
/**
* Slightly hackish to use reflection, but asserting different parameters
- * to consecutive calls of DatabaseBase::select in phpunit is error prone
+ * to consecutive calls of Database::select in phpunit is error prone
*
* @dataProvider provider_readerSelectConditions
*/
@@ -214,7 +214,7 @@ class BatchRowUpdateTest extends MediaWikiTestCase {
protected function consecutivelyReturnFromSelect( array $results ) {
$retvals = [];
foreach ( $results as $rows ) {
- // The DatabaseBase::select method returns iterators, so we do too.
+ // The Database::select method returns iterators, so we do too.
$retvals[] = $this->returnValue( new ArrayIterator( $rows ) );
}
@@ -235,8 +235,7 @@ class BatchRowUpdateTest extends MediaWikiTestCase {
}
protected function mockDb() {
- // Cant mock from DatabaseType or DatabaseBase, they dont
- // have the full gamut of methods
+ // @TODO: mock from Database
// FIXME: the constructor normally sets mAtomicLevels and mSrvCache
$databaseMysql = $this->getMockBuilder( 'DatabaseMysql' )
->disableOriginalConstructor()