Attempt to flatten out PHP files in sub extensions

In an attempt to be able to have easier code coverage...

Bug: T377750
Change-Id: I556f5f2753fae77df4f34b64bccdb7d68f2825b0
This commit is contained in:
Reedy 2024-10-23 23:59:50 +01:00
parent 407144cbe7
commit 9f2e976f10
39 changed files with 19 additions and 25 deletions

View file

@ -5,11 +5,6 @@ $cfg = require __DIR__ . '/../vendor/mediawiki/mediawiki-phan-config/src/config.
$cfg['directory_list'] = array_merge(
$cfg['directory_list'],
[
'FancyCaptcha/',
'hCaptcha/',
'QuestyCaptcha/',
'ReCaptchaNoCaptcha/',
'SimpleCaptcha/',
'../../extensions/AbuseFilter',
]
);

View file

@ -18,11 +18,11 @@
]
},
"AutoloadClasses": {
"FancyCaptcha": "includes/FancyCaptcha.php",
"MediaWiki\\Extension\\ConfirmEdit\\FancyCaptcha\\FancyCaptcha": "includes/FancyCaptcha.php"
"FancyCaptcha": "../includes/FancyCaptcha/FancyCaptcha.php",
"MediaWiki\\Extension\\ConfirmEdit\\FancyCaptcha\\FancyCaptcha": "../includes/FancyCaptcha/FancyCaptcha.php"
},
"AutoloadNamespaces": {
"MediaWiki\\Extension\\ConfirmEdit\\FancyCaptcha\\": "includes/"
"MediaWiki\\Extension\\ConfirmEdit\\FancyCaptcha\\": "../includes/FancyCaptcha/"
},
"ResourceModules": {
"ext.confirmEdit.fancyCaptcha.styles": {
@ -38,7 +38,7 @@
},
"ResourceFileModulePaths": {
"localBasePath": "resources",
"remoteExtPath": "ConfirmEdit/FancyCaptcha/resources"
"remoteExtPath": "ConfirmEdit/resources"
},
"callback": "MediaWiki\\Extension\\ConfirmEdit\\Hooks::onFancyCaptchaSetup",
"config": {

View file

@ -13,11 +13,11 @@
]
},
"AutoloadClasses": {
"QuestyCaptcha": "includes/QuestyCaptcha.php",
"MediaWiki\\Extension\\ConfirmEdit\\QuestyCaptcha\\QuestyCaptcha": "includes/QuestyCaptcha.php"
"QuestyCaptcha": "../includes/QuestyCaptcha/QuestyCaptcha.php",
"MediaWiki\\Extension\\ConfirmEdit\\QuestyCaptcha\\QuestyCaptcha": "../includes/QuestyCaptcha/QuestyCaptcha.php"
},
"AutoloadNamespaces": {
"MediaWiki\\Extension\\ConfirmEdit\\QuestyCaptcha\\": "includes/"
"MediaWiki\\Extension\\ConfirmEdit\\QuestyCaptcha\\": "../includes/QuestyCaptcha/"
},
"config": {
"CaptchaClass": {

View file

@ -14,7 +14,7 @@
]
},
"AutoloadNamespaces": {
"MediaWiki\\Extension\\ConfirmEdit\\ReCaptchaNoCaptcha\\": "includes/"
"MediaWiki\\Extension\\ConfirmEdit\\ReCaptchaNoCaptcha\\": "../includes/ReCaptchaNoCaptcha/"
},
"config": {
"CaptchaClass": {
@ -32,7 +32,7 @@
},
"ResourceFileModulePaths": {
"localBasePath": "resources",
"remoteExtPath": "ConfirmEdit/ReCaptchaNoCaptcha/resources"
"remoteExtPath": "ConfirmEdit/resources"
},
"ResourceModules": {
"ext.confirmEdit.reCaptchaNoCaptcha.visualEditor": {

View file

@ -15,7 +15,7 @@
]
},
"AutoloadNamespaces": {
"MediaWiki\\Extension\\ConfirmEdit\\Turnstile\\": "includes/"
"MediaWiki\\Extension\\ConfirmEdit\\Turnstile\\": "../includes/Turnstile/"
},
"config": {
"CaptchaClass": {
@ -33,7 +33,7 @@
},
"ResourceFileModulePaths": {
"localBasePath": "resources",
"remoteExtPath": "ConfirmEdit/Turnstile/resources"
"remoteExtPath": "ConfirmEdit/resources"
},
"ResourceModules": {
"ext.confirmEdit.turnstile.visualEditor": {

View file

@ -62,8 +62,7 @@
"MediaWiki\\Extension\\ConfirmEdit\\Store\\CaptchaCacheStore": "includes/Store/CaptchaCacheStore.php"
},
"AutoloadNamespaces": {
"MediaWiki\\Extension\\ConfirmEdit\\": "includes/",
"MediaWiki\\Extension\\ConfirmEdit\\SimpleCaptcha\\": "SimpleCaptcha/"
"MediaWiki\\Extension\\ConfirmEdit\\": "includes/"
},
"ResourceModules": {
"ext.confirmEdit.editPreview.ipwhitelist.styles": {
@ -74,7 +73,7 @@
"dependencies": "ext.confirmEdit.CaptchaInputWidget"
},
"ext.confirmEdit.simpleCaptcha": {
"styles": "../SimpleCaptcha/resources/ext.confirmEdit.simpleCaptcha.css"
"styles": "ext.confirmEdit.simpleCaptcha.css"
}
},
"attributes": {

View file

@ -14,7 +14,7 @@
]
},
"AutoloadNamespaces": {
"MediaWiki\\Extension\\ConfirmEdit\\hCaptcha\\": "includes/"
"MediaWiki\\Extension\\ConfirmEdit\\hCaptcha\\": "../includes/hCaptcha/"
},
"config": {
"CaptchaClass": {
@ -42,7 +42,7 @@
},
"ResourceFileModulePaths": {
"localBasePath": "resources",
"remoteExtPath": "ConfirmEdit/hCaptcha/resources"
"remoteExtPath": "ConfirmEdit/resources/hCaptcha"
},
"ResourceModules": {
"ext.confirmEdit.hCaptcha.visualEditor": {

View file

Before

Width:  |  Height:  |  Size: 6 KiB

After

Width:  |  Height:  |  Size: 6 KiB

View file

Before

Width:  |  Height:  |  Size: 245 B

After

Width:  |  Height:  |  Size: 245 B

View file

@ -21,7 +21,7 @@ class HTMLFancyCaptchaFieldTest extends MediaWikiIntegrationTestCase {
'wgAutoloadClasses',
[
'MediaWiki\\Extension\\ConfirmEdit\\FancyCaptcha\\HTMLFancyCaptchaField'
=> __DIR__ . '/../../FancyCaptcha/includes/HTMLFancyCaptchaField.php'
=> __DIR__ . '/../../includes/FancyCaptcha/HTMLFancyCaptchaField.php'
]
);
}

View file

@ -19,7 +19,7 @@ class HTMLReCaptchaNoCaptchaFieldTest extends MediaWikiIntegrationTestCase {
'wgAutoloadClasses',
[
'MediaWiki\\Extension\\ConfirmEdit\\ReCaptchaNoCaptcha\\HTMLReCaptchaNoCaptchaField'
=> __DIR__ . '/../../ReCaptchaNoCaptcha/includes/HTMLReCaptchaNoCaptchaField.php'
=> __DIR__ . '/../../includes/ReCaptchaNoCaptcha/HTMLReCaptchaNoCaptchaField.php'
]
);
}

View file

@ -13,7 +13,7 @@ class QuestyCaptchaTest extends MediaWikiIntegrationTestCase {
$this->mergeMwGlobalArrayValue(
'wgAutoloadClasses',
[ 'MediaWiki\\Extension\\ConfirmEdit\\QuestyCaptcha\\QuestyCaptcha'
=> __DIR__ . '/../../QuestyCaptcha/includes/QuestyCaptcha.php' ]
=> __DIR__ . '/../../includes/QuestyCaptcha/QuestyCaptcha.php' ]
);
}

View file

@ -15,7 +15,7 @@ class ReCaptchaNoCaptchaAuthenticationRequestTest extends AuthenticationRequestT
'wgAutoloadClasses',
[
'MediaWiki\\Extension\\ConfirmEdit\\ReCaptchaNoCaptcha\\ReCaptchaNoCaptchaAuthenticationRequest'
=> __DIR__ . '/../../ReCaptchaNoCaptcha/includes/ReCaptchaNoCaptchaAuthenticationRequest.php'
=> __DIR__ . '/../..//includes/ReCaptchaNoCaptcha/ReCaptchaNoCaptchaAuthenticationRequest.php'
]
);
}