Awight has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/196986

Change subject: Do not include the bannerChoiceData RL module from tests
......................................................................

Do not include the bannerChoiceData RL module from tests

This data is mocked anyway, and loading the module involves PHP-side
configuration issues which cannot be easily resolved from QUnit tests.

Bug: T91763
Change-Id: I92731206c8e0ee3bb7a9f4b59be626fd78a3a44d
---
M CentralNotice.hooks.php
1 file changed, 7 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CentralNotice 
refs/changes/86/196986/1

diff --git a/CentralNotice.hooks.php b/CentralNotice.hooks.php
index 12860a2..0f5f1ca 100644
--- a/CentralNotice.hooks.php
+++ b/CentralNotice.hooks.php
@@ -446,6 +446,13 @@
                }
        }
 
+       // Disconnect bannerChoiceData module during testing.
+       $controllerDependencies = 
&$wgResourceModules['ext.centralNotice.bannerController']['dependencies'];
+       $dataModuleIndex = array_search( 'ext.centralNotice.bannerChoiceData', 
$controllerDependencies );
+       if ( $dataModuleIndex !== false ) {
+               unset( $dependencies[$dataModuleIndex] );
+       }
+
        return true;
 }
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I92731206c8e0ee3bb7a9f4b59be626fd78a3a44d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/CentralNotice
Gerrit-Branch: master
Gerrit-Owner: Awight <[email protected]>

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

Reply via email to