Umherirrender has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/399963 )

Change subject: Change doc type from DatabaseBase to IDatabase
......................................................................

Change doc type from DatabaseBase to IDatabase

Change-Id: I853b7cef85fdd77c28a947a8f3601f84ba17359a
---
M includes/EchoDbFactory.php
M includes/UnreadWikis.php
M includes/mapper/NotificationMapper.php
M tests/phpunit/gateway/UserNotificationGatewayTest.php
M tests/phpunit/mapper/EventMapperTest.php
M tests/phpunit/mapper/NotificationMapperTest.php
M tests/phpunit/mapper/TargetPageMapperTest.php
7 files changed, 10 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Echo 
refs/changes/63/399963/1

diff --git a/includes/EchoDbFactory.php b/includes/EchoDbFactory.php
index be2a59a..cd47f27 100644
--- a/includes/EchoDbFactory.php
+++ b/includes/EchoDbFactory.php
@@ -73,7 +73,7 @@
         * Get the database connection for Echo
         * @param int $db Index of the connection to get
         * @param mixed $groups Query groups.
-        * @return IDatabase
+        * @return \Wikimedia\Rdbms\IDatabase
         */
        public function getEchoDb( $db, $groups = [] ) {
                return $this->getLB()->getConnection( $db, $groups );
@@ -82,7 +82,7 @@
        /**
         * @param int $db Index of the connection to get
         * @param array $groups Query groups
-        * @return bool|IDatabase false if no shared db is configured
+        * @return bool|\Wikimedia\Rdbms\IDatabase false if no shared db is 
configured
         */
        public function getSharedDb( $db, $groups = [] ) {
                if ( !$this->shared ) {
@@ -102,7 +102,7 @@
         * @param int $db Index of the connection to get
         * @param mixed $groups Query groups.
         * @param string|bool $wiki The wiki ID, or false for the current wiki
-        * @return IDatabase
+        * @return \Wikimedia\Rdbms\IDatabase
         */
        public static function getDB( $db, $groups = [], $wiki = false ) {
                global $wgEchoCluster;
diff --git a/includes/UnreadWikis.php b/includes/UnreadWikis.php
index 1381ce0..8a45a46 100644
--- a/includes/UnreadWikis.php
+++ b/includes/UnreadWikis.php
@@ -45,7 +45,7 @@
 
        /**
         * @param int $index DB_* constant
-        * @return bool|DatabaseBase
+        * @return bool|\Wikimedia\Rdbms\IDatabase
         */
        private function getDB( $index ) {
                return $this->dbFactory->getSharedDb( $index );
diff --git a/includes/mapper/NotificationMapper.php 
b/includes/mapper/NotificationMapper.php
index 9a8d777..02d6310 100644
--- a/includes/mapper/NotificationMapper.php
+++ b/includes/mapper/NotificationMapper.php
@@ -1,5 +1,7 @@
 <?php
 
+use Wikimedia\Rdbms\IDatabase;
+
 /**
  * Database mapper for EchoNotification model
  */
diff --git a/tests/phpunit/gateway/UserNotificationGatewayTest.php 
b/tests/phpunit/gateway/UserNotificationGatewayTest.php
index b88d609..82adfe7 100644
--- a/tests/phpunit/gateway/UserNotificationGatewayTest.php
+++ b/tests/phpunit/gateway/UserNotificationGatewayTest.php
@@ -93,7 +93,7 @@
        }
 
        /**
-        * Mock object of DatabaseMysql ( DatabaseBase )
+        * Mock object of DatabaseMysql ( \Wikimedia\Rdbms\IDatabase )
         */
        protected function mockDb( array $dbResult = [] ) {
                $dbResult += [
diff --git a/tests/phpunit/mapper/EventMapperTest.php 
b/tests/phpunit/mapper/EventMapperTest.php
index e9528ca..1483ece 100644
--- a/tests/phpunit/mapper/EventMapperTest.php
+++ b/tests/phpunit/mapper/EventMapperTest.php
@@ -99,7 +99,7 @@
        }
 
        /**
-        * Mock object of DatabaseMysql ( DatabaseBase )
+        * Mock object of DatabaseMysql ( \Wikimedia\Rdbms\IDatabase )
         */
        protected function mockDb( array $dbResult ) {
                $dbResult += [
diff --git a/tests/phpunit/mapper/NotificationMapperTest.php 
b/tests/phpunit/mapper/NotificationMapperTest.php
index 420c093..29c9355 100644
--- a/tests/phpunit/mapper/NotificationMapperTest.php
+++ b/tests/phpunit/mapper/NotificationMapperTest.php
@@ -216,7 +216,7 @@
        }
 
        /**
-        * Mock object of DatabaseMysql ( DatabaseBase )
+        * Mock object of DatabaseMysql ( \Wikimedia\Rdbms\IDatabase )
         */
        protected function mockDb( array $dbResult ) {
                $dbResult += [
diff --git a/tests/phpunit/mapper/TargetPageMapperTest.php 
b/tests/phpunit/mapper/TargetPageMapperTest.php
index 522ee34..356d738 100644
--- a/tests/phpunit/mapper/TargetPageMapperTest.php
+++ b/tests/phpunit/mapper/TargetPageMapperTest.php
@@ -69,7 +69,7 @@
        }
 
        /**
-        * Mock object of DatabaseMysql ( DatabaseBase )
+        * Mock object of DatabaseMysql ( \Wikimedia\Rdbms\IDatabase )
         */
        protected function mockDb( array $dbResult ) {
                $dbResult += [

-- 
To view, visit https://gerrit.wikimedia.org/r/399963
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I853b7cef85fdd77c28a947a8f3601f84ba17359a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Echo
Gerrit-Branch: master
Gerrit-Owner: Umherirrender <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to