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

Change subject: Prevent PHPDBG from issuing notices in unit tests
......................................................................

Prevent PHPDBG from issuing notices in unit tests

Although issuing PHP notices in unit tests is only a nice-to-have, the cause
is PHPDBG has no special treatment in JobQueueGroup at the contrary of the
PHP SAPI 'cli', and it may be desirable both 'command line SAPIs' have the
same behaviour.

This is the most apparent difference between cli and phpdbg but there could
be a dozen of other occurrences (see bug), potentially creating differences
in unit tests depending on the SAPI.

Bug: T162591
Change-Id: Idf9c14db72f1f768c5a17b49ed689a05922c57d3
---
M includes/jobqueue/JobQueueGroup.php
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/55/347355/1

diff --git a/includes/jobqueue/JobQueueGroup.php 
b/includes/jobqueue/JobQueueGroup.php
index 71d68d9..9f78404 100644
--- a/includes/jobqueue/JobQueueGroup.php
+++ b/includes/jobqueue/JobQueueGroup.php
@@ -170,7 +170,7 @@
         * @since 1.26
         */
        public function lazyPush( $jobs ) {
-               if ( PHP_SAPI === 'cli' ) {
+               if ( PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg' ) {
                        $this->push( $jobs );
                        return;
                }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Idf9c14db72f1f768c5a17b49ed689a05922c57d3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Seb35 <se...@seb35.fr>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to