66df315e1050f79c1e98fb552ebf6c30343516d1
[lhc/web/wiklou.git] / tests / common / TestsAutoLoader.php
1 <?php
2 /**
3 * AutoLoader for the testing suite.
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License along
16 * with this program; if not, write to the Free Software Foundation, Inc.,
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 * http://www.gnu.org/copyleft/gpl.html
19 *
20 * @file
21 * @ingroup Testing
22 */
23
24 global $wgAutoloadClasses;
25 $testDir = __DIR__ . "/..";
26
27 $wgAutoloadClasses += [
28
29 # tests/common
30 'TestSetup' => "$testDir/common/TestSetup.php",
31
32 # tests/parser
33 'DbTestPreviewer' => "$testDir/parser/DbTestPreviewer.php",
34 'DbTestRecorder' => "$testDir/parser/DbTestRecorder.php",
35 'DjVuSupport' => "$testDir/parser/DjVuSupport.php",
36 'TestRecorder' => "$testDir/parser/TestRecorder.php",
37 'MultiTestRecorder' => "$testDir/parser/MultiTestRecorder.php",
38 'ParserTestMockParser' => "$testDir/parser/ParserTestMockParser.php",
39 'ParserTestRunner' => "$testDir/parser/ParserTestRunner.php",
40 'ParserTestParserHook' => "$testDir/parser/ParserTestParserHook.php",
41 'ParserTestPrinter' => "$testDir/parser/ParserTestPrinter.php",
42 'ParserTestResult' => "$testDir/parser/ParserTestResult.php",
43 'ParserTestResultNormalizer' => "$testDir/parser/ParserTestResultNormalizer.php",
44 'PhpunitTestRecorder' => "$testDir/parser/PhpunitTestRecorder.php",
45 'TestFileEditor' => "$testDir/parser/TestFileEditor.php",
46 'TestFileReader' => "$testDir/parser/TestFileReader.php",
47 'TestRecorder' => "$testDir/parser/TestRecorder.php",
48 'TidySupport' => "$testDir/parser/TidySupport.php",
49
50 # tests/phpunit
51 'MediaWikiTestCase' => "$testDir/phpunit/MediaWikiTestCase.php",
52 'MediaWikiPHPUnitTestListener' => "$testDir/phpunit/MediaWikiPHPUnitTestListener.php",
53 'MediaWikiLangTestCase' => "$testDir/phpunit/MediaWikiLangTestCase.php",
54 'ResourceLoaderTestCase' => "$testDir/phpunit/ResourceLoaderTestCase.php",
55 'ResourceLoaderTestModule' => "$testDir/phpunit/ResourceLoaderTestCase.php",
56 'ResourceLoaderFileModuleTestModule' => "$testDir/phpunit/ResourceLoaderTestCase.php",
57 'EmptyResourceLoader' => "$testDir/phpunit/ResourceLoaderTestCase.php",
58 'TestUser' => "$testDir/phpunit/includes/TestUser.php",
59 'TestUserRegistry' => "$testDir/phpunit/includes/TestUserRegistry.php",
60 'LessFileCompilationTest' => "$testDir/phpunit/LessFileCompilationTest.php",
61
62 # tests/phpunit/includes
63 'RevisionStorageTest' => "$testDir/phpunit/includes/RevisionStorageTest.php",
64 'TestingAccessWrapper' => "$testDir/phpunit/includes/TestingAccessWrapper.php",
65 'TestLogger' => "$testDir/phpunit/includes/TestLogger.php",
66
67 # tests/phpunit/includes/api
68 'ApiFormatTestBase' => "$testDir/phpunit/includes/api/format/ApiFormatTestBase.php",
69 'ApiQueryTestBase' => "$testDir/phpunit/includes/api/query/ApiQueryTestBase.php",
70 'ApiQueryContinueTestBase' => "$testDir/phpunit/includes/api/query/ApiQueryContinueTestBase.php",
71 'ApiTestCase' => "$testDir/phpunit/includes/api/ApiTestCase.php",
72 'ApiTestCaseUpload' => "$testDir/phpunit/includes/api/ApiTestCaseUpload.php",
73 'ApiTestContext' => "$testDir/phpunit/includes/api/ApiTestContext.php",
74 'MockApi' => "$testDir/phpunit/includes/api/MockApi.php",
75 'MockApiQueryBase' => "$testDir/phpunit/includes/api/MockApiQueryBase.php",
76 'UserWrapper' => "$testDir/phpunit/includes/api/UserWrapper.php",
77 'RandomImageGenerator' => "$testDir/phpunit/includes/api/RandomImageGenerator.php",
78
79 # tests/phpunit/includes/auth
80 'MediaWiki\\Auth\\AuthenticationRequestTestCase' =>
81 "$testDir/phpunit/includes/auth/AuthenticationRequestTestCase.php",
82
83 # tests/phpunit/includes/changes
84 'TestRecentChangesHelper' => "$testDir/phpunit/includes/changes/TestRecentChangesHelper.php",
85
86 # tests/phpunit/includes/content
87 'DummyContentHandlerForTesting' =>
88 "$testDir/phpunit/mocks/content/DummyContentHandlerForTesting.php",
89 'DummyContentForTesting' => "$testDir/phpunit/mocks/content/DummyContentForTesting.php",
90 'DummyNonTextContentHandler' => "$testDir/phpunit/mocks/content/DummyNonTextContentHandler.php",
91 'DummyNonTextContent' => "$testDir/phpunit/mocks/content/DummyNonTextContent.php",
92 'ContentHandlerTest' => "$testDir/phpunit/includes/content/ContentHandlerTest.php",
93 'JavaScriptContentTest' => "$testDir/phpunit/includes/content/JavaScriptContentTest.php",
94 'TextContentTest' => "$testDir/phpunit/includes/content/TextContentTest.php",
95 'WikitextContentTest' => "$testDir/phpunit/includes/content/WikitextContentTest.php",
96
97 # tests/phpunit/includes/db
98 'DatabaseTestHelper' => "$testDir/phpunit/includes/db/DatabaseTestHelper.php",
99
100 # tests/phpunit/includes/diff
101 'FakeDiffOp' => "$testDir/phpunit/includes/diff/FakeDiffOp.php",
102
103 # tests/phpunit/includes/logging
104 'LogFormatterTestCase' => "$testDir/phpunit/includes/logging/LogFormatterTestCase.php",
105
106 # tests/phpunit/includes/page
107 'WikiPageTest' => "$testDir/phpunit/includes/page/WikiPageTest.php",
108
109 # tests/phpunit/includes/parser
110 'ParserIntegrationTest' => "$testDir/phpunit/includes/parser/ParserIntegrationTest.php",
111
112 # tests/phpunit/includes/password
113 'PasswordTestCase' => "$testDir/phpunit/includes/password/PasswordTestCase.php",
114
115 # tests/phpunit/includes/resourceloader
116 'ResourceLoaderImageModuleTest' =>
117 "$testDir/phpunit/includes/resourceloader/ResourceLoaderImageModuleTest.php",
118 'ResourceLoaderImageModuleTestable' =>
119 "$testDir/phpunit/includes/resourceloader/ResourceLoaderImageModuleTest.php",
120
121 # tests/phpunit/includes/session
122 'MediaWiki\\Session\\TestBagOStuff' => "$testDir/phpunit/includes/session/TestBagOStuff.php",
123 'MediaWiki\\Session\\TestUtils' => "$testDir/phpunit/includes/session/TestUtils.php",
124
125 # tests/phpunit/includes/site
126 'SiteTest' => "$testDir/phpunit/includes/site/SiteTest.php",
127 'TestSites' => "$testDir/phpunit/includes/site/TestSites.php",
128
129 # tests/phpunit/includes/specialpage
130 'SpecialPageTestHelper' => "$testDir/phpunit/includes/specialpage/SpecialPageTestHelper.php",
131
132 # tests/phpunit/includes/specials
133 'SpecialPageTestBase' => "$testDir/phpunit/includes/specials/SpecialPageTestBase.php",
134 'SpecialPageExecutor' => "$testDir/phpunit/includes/specials/SpecialPageExecutor.php",
135
136 # tests/phpunit/languages
137 'LanguageClassesTestCase' => "$testDir/phpunit/languages/LanguageClassesTestCase.php",
138
139 # tests/phpunit/includes/libs
140 'GenericArrayObjectTest' => "$testDir/phpunit/includes/libs/GenericArrayObjectTest.php",
141
142 # tests/phpunit/maintenance
143 'DumpTestCase' => "$testDir/phpunit/maintenance/DumpTestCase.php",
144
145 # tests/phpunit/media
146 'FakeDimensionFile' => "$testDir/phpunit/includes/media/FakeDimensionFile.php",
147 'MediaWikiMediaTestCase' => "$testDir/phpunit/includes/media/MediaWikiMediaTestCase.php",
148
149 # tests/phpunit/mocks
150 'MockFSFile' => "$testDir/phpunit/mocks/filebackend/MockFSFile.php",
151 'MockFileBackend' => "$testDir/phpunit/mocks/filebackend/MockFileBackend.php",
152 'MockLocalRepo' => "$testDir/phpunit/mocks/filerepo/MockLocalRepo.php",
153 'MockBitmapHandler' => "$testDir/phpunit/mocks/media/MockBitmapHandler.php",
154 'MockImageHandler' => "$testDir/phpunit/mocks/media/MockImageHandler.php",
155 'MockSvgHandler' => "$testDir/phpunit/mocks/media/MockSvgHandler.php",
156 'MockDjVuHandler' => "$testDir/phpunit/mocks/media/MockDjVuHandler.php",
157 'MockOggHandler' => "$testDir/phpunit/mocks/media/MockOggHandler.php",
158 'MockMediaHandlerFactory' => "$testDir/phpunit/mocks/media/MockMediaHandlerFactory.php",
159 'MockWebRequest' => "$testDir/phpunit/mocks/MockWebRequest.php",
160 'MediaWiki\\Session\\DummySessionBackend'
161 => "$testDir/phpunit/mocks/session/DummySessionBackend.php",
162 'DummySessionProvider' => "$testDir/phpunit/mocks/session/DummySessionProvider.php",
163
164 # tests/suites
165 'ParserTestFileSuite' => "$testDir/phpunit/suites/ParserTestFileSuite.php",
166 'ParserTestTopLevelSuite' => "$testDir/phpunit/suites/ParserTestTopLevelSuite.php",
167 ];