Skip to content

Commit 28ea93e

Browse files
authored
Merge pull request #810 from Abijeet/patch-1
Use classes namespaced in MW 1.40 after removal
2 parents 2ae3295 + aab6186 commit 28ea93e

File tree

16 files changed

+24
-40
lines changed

16 files changed

+24
-40
lines changed

.github/workflows/ci.yml

Lines changed: 6 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,6 @@ jobs:
1414
strategy:
1515
matrix:
1616
include:
17-
- mw: 'REL1_35'
18-
php: 7.4
19-
experimental: false
20-
- mw: 'REL1_36'
21-
php: 7.4
22-
experimental: false
23-
- mw: 'REL1_37'
24-
php: 7.4
25-
experimental: false
26-
- mw: 'REL1_38'
27-
php: 8.0
28-
experimental: false
29-
- mw: 'REL1_39'
30-
php: 8.1
3117
experimental: false
3218
- mw: 'REL1_40'
3319
php: 8.1
@@ -95,13 +81,13 @@ jobs:
9581

9682
- name: Run PHPUnit
9783
run: php tests/phpunit/phpunit.php -c extensions/Maps
98-
if: matrix.mw != 'REL1_37'
84+
if: matrix.mw != 'REL1_43'
9985

10086
- name: Run PHPUnit with code coverage
10187
run: |
10288
php tests/phpunit/phpunit.php -c extensions/Maps --coverage-clover coverage.xml
10389
bash <(curl -s https://codecov.io/bash)
104-
if: matrix.mw == 'REL1_38'
90+
if: matrix.mw == 'REL1_43'
10591

10692

10793
# Psalm:
@@ -171,7 +157,7 @@ jobs:
171157
- name: Setup PHP
172158
uses: shivammathur/setup-php@v2
173159
with:
174-
php-version: 8.0
160+
php-version: 8.2
175161
extensions: mbstring
176162
tools: composer, cs2pr
177163

@@ -198,7 +184,7 @@ jobs:
198184
- name: Install MediaWiki
199185
if: steps.cache-mediawiki.outputs.cache-hit != 'true'
200186
working-directory: ~
201-
run: bash EarlyCopy/.github/workflows/installMediaWiki.sh REL1_39 Maps
187+
run: bash EarlyCopy/.github/workflows/installMediaWiki.sh REL1_43 Maps
202188

203189
- uses: actions/checkout@v4
204190
with:
@@ -231,7 +217,7 @@ jobs:
231217
- name: Setup PHP
232218
uses: shivammathur/setup-php@v2
233219
with:
234-
php-version: 8.0
220+
php-version: 8.2
235221
extensions: mbstring, intl, php-ast
236222
tools: composer
237223

@@ -258,7 +244,7 @@ jobs:
258244
- name: Install MediaWiki
259245
if: steps.cache-mediawiki.outputs.cache-hit != 'true'
260246
working-directory: ~
261-
run: bash EarlyCopy/.github/workflows/installMediaWiki.sh REL1_39 Maps
247+
run: bash EarlyCopy/.github/workflows/installMediaWiki.sh REL1_43 Maps
262248

263249
- uses: actions/checkout@v4
264250
with:

extension.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"type": "parserhook",
1313

1414
"requires": {
15-
"MediaWiki": ">= 1.35.0",
15+
"MediaWiki": ">= 1.40.0",
1616
"platform": {
1717
"php": ">= 7.4"
1818
}

src/GeoJsonPages/GeoJsonLegacyContent.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
use Maps\GeoJsonPages\GeoJsonContent as GeoJsonPagesGeoJsonContent;
88
use Maps\MapsFactory;
99
use Maps\Presentation\OutputFacade;
10+
use MediaWiki\Title\Title;
1011
use ParserOptions;
1112
use ParserOutput;
12-
use Title;
1313

1414
/**
1515
* @deprecated This class should be removed when Maps drops support for MediaWiki 1.37.

src/GeoJsonPages/GeoJsonMapPageUi.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
namespace Maps\GeoJsonPages;
66

7-
use Html;
7+
use MediaWiki\Html\Html;
88
use Maps\Presentation\OutputFacade;
99

1010
class GeoJsonMapPageUi {

src/GeoJsonPages/Semantic/SemanticGeoJsonStore.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@
55
namespace Maps\GeoJsonPages\Semantic;
66

77
use Maps\GeoJsonPages\GeoJsonStore;
8+
use MediaWiki\Title\Title;
89
use Onoi\EventDispatcher\EventDispatcher;
910
use SMW\DIProperty;
1011
use SMW\ParserData;
1112
use SMWDIContainer;
12-
use Title;
1313

1414
class SemanticGeoJsonStore implements GeoJsonStore {
1515

src/GoogleMapsService.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
namespace Maps;
66

7-
use Html;
7+
use MediaWiki\Html\Html;
88
use Maps\Map\MapData;
99
use ParamProcessor\ProcessedParam;
1010
use ParamProcessor\ProcessingResult;

src/LeafletService.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
namespace Maps;
66

7-
use Html;
7+
use MediaWiki\Html\Html;
88
use Maps\DataAccess\ImageRepository;
99
use Maps\Map\MapData;
1010
use ParamProcessor\ParameterTypes;

src/LegacyMapEditor/MapEditorHtml.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
namespace Maps\LegacyMapEditor;
66

77
use ContextSource;
8-
use Html;
8+
use MediaWiki\Html\Html;
99

1010
/**
1111
* Class to Handle HTML generation for Special:MapEditor

src/Map/MapHtmlBuilder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
namespace Maps\Map;
66

77
use FormatJson;
8-
use Html;
8+
use MediaWiki\Html\Html;
99

1010
class MapHtmlBuilder {
1111

src/Map/SemanticFormat/MapPrinter.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
namespace Maps\Map\SemanticFormat;
66

7-
use Linker;
7+
use MediaWiki\Linker\Linker;
88
use Maps\FileUrlFinder;
99
use Maps\LegacyModel\BaseElement;
1010
use Maps\LegacyModel\Location;
@@ -16,11 +16,11 @@
1616
use Maps\SemanticMW\QueryHandler;
1717
use Maps\WikitextParsers\LocationParser;
1818
use MediaWiki\MediaWikiServices;
19+
use MediaWiki\Title\Title;
1920
use Parser;
2021
use SMW\Query\QueryResult;
2122
use SMW\Query\ResultPrinters\ResultPrinter;
2223
use SMWOutputs;
23-
use Title;
2424

2525
/**
2626
* @licence GNU GPL v2+

0 commit comments

Comments
 (0)