jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/400401 )

Change subject: Add strict type hints to test function headers
......................................................................


Add strict type hints to test function headers

This should be trivial to review. If CI sucessfully runs these tests,
there can't be anything wrong with the type hints I'm adding, right?

Change-Id: I84ea7f7332648deab6065c764a126f8582105044
---
M tests/phpunit/includes/CacheTest.php
M tests/phpunit/includes/Hooks/ChangesListHooksHandlerTest.php
M tests/phpunit/includes/Parser/ScoreParserTest.php
M tests/phpunit/includes/RangeTest.php
4 files changed, 7 insertions(+), 7 deletions(-)

Approvals:
  Ladsgroup: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/tests/phpunit/includes/CacheTest.php 
b/tests/phpunit/includes/CacheTest.php
index a61b76b..d536cb0 100644
--- a/tests/phpunit/includes/CacheTest.php
+++ b/tests/phpunit/includes/CacheTest.php
@@ -145,7 +145,7 @@
        /**
         * @dataProvider processRevisionProvider
         */
-       public function testProcessRevision( $revisionData, $expected, $revId ) 
{
+       public function testProcessRevision( array $revisionData, array 
$expected, $revId ) {
                $data = [];
                $this->cache->processRevision( $data, $revId, $revisionData );
 
@@ -213,7 +213,7 @@
        /**
         * @dataProvider storeScoresProvider
         */
-       public function testStoreScores( $scores, $expected, $revIds ) {
+       public function testStoreScores( array $scores, array $expected, array 
$revIds ) {
                $this->setMwGlobals( [
                        'wgOresWikiId' => 'wiki',
                ] );
diff --git a/tests/phpunit/includes/Hooks/ChangesListHooksHandlerTest.php 
b/tests/phpunit/includes/Hooks/ChangesListHooksHandlerTest.php
index 27efc3d..4fc1796 100644
--- a/tests/phpunit/includes/Hooks/ChangesListHooksHandlerTest.php
+++ b/tests/phpunit/includes/Hooks/ChangesListHooksHandlerTest.php
@@ -78,7 +78,7 @@
        /**
         * @dataProvider onChangesListSpecialPageQuery_provider
         */
-       public function testOnChangesListSpecialPageQuery( $modelConfig, 
$expectedQuery ) {
+       public function testOnChangesListSpecialPageQuery( array $modelConfig, 
array $expectedQuery ) {
                $this->setMwGlobals( [
                        'wgUser' => $this->user,
                        'wgOresModels' => $modelConfig
diff --git a/tests/phpunit/includes/Parser/ScoreParserTest.php 
b/tests/phpunit/includes/Parser/ScoreParserTest.php
index 7f2d1c8..91473b3 100644
--- a/tests/phpunit/includes/Parser/ScoreParserTest.php
+++ b/tests/phpunit/includes/Parser/ScoreParserTest.php
@@ -83,7 +83,7 @@
        /**
         * @dataProvider processRevisionProvider
         */
-       public function testProcessRevision( $revisionData, $expected, $revId ) 
{
+       public function testProcessRevision( array $revisionData, array 
$expected, $revId ) {
                $modelData = [
                        'reverted' => [ 'id' => self::REVERTED, 'version' => 
'0.0.1' ],
                        'damaging' => [ 'id' => self::DAMAGING, 'version' => 
'0.0.2' ],
@@ -145,7 +145,7 @@
        /**
         * @dataProvider processRevisionInvalidProvider
         */
-       public function testProcessRevisionInvalid( $revisionData, $revId ) {
+       public function testProcessRevisionInvalid( array $revisionData, $revId 
) {
                $this->setExpectedException( InvalidArgumentException::class );
                $modelData = [
                        'reverted' => [ 'id' => self::REVERTED, 'version' => 
'0.0.1' ],
diff --git a/tests/phpunit/includes/RangeTest.php 
b/tests/phpunit/includes/RangeTest.php
index 60d523e..4e48b08 100644
--- a/tests/phpunit/includes/RangeTest.php
+++ b/tests/phpunit/includes/RangeTest.php
@@ -40,7 +40,7 @@
        /**
         * @dataProvider overlapsProvider
         */
-       public function testOverlaps( $r1, $r2, $expectedOverlap ) {
+       public function testOverlaps( array $r1, array $r2, $expectedOverlap ) {
                $r1 = new Range( $r1[0], $r1[1] );
                $r2 = new Range( $r2[0], $r2[1] );
                $this->assertEquals( $expectedOverlap, $r1->overlaps( $r2 ) );
@@ -58,7 +58,7 @@
        /**
         * @dataProvider combineWithProvider
         */
-       public function testCombineWith( $r1, $r2, $expectedRange ) {
+       public function testCombineWith( array $r1, array $r2, $expectedRange ) 
{
                $r1 = new Range( $r1[0], $r1[1] );
                $r2 = new Range( $r2[0], $r2[1] );
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I84ea7f7332648deab6065c764a126f8582105044
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ORES
Gerrit-Branch: master
Gerrit-Owner: Thiemo Kreuz (WMDE) <[email protected]>
Gerrit-Reviewer: Ladsgroup <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

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

Reply via email to