Commit graph

10 commits

Author SHA1 Message Date
Bartosz Dziewoński
62cfede3fa PermissionsError: Deprecate public properties
Follow-up to 298ec8382b, which replaced
`public $errors` with `public $status`, causing T372181.

* Add a deprecated fallback getter/setter for $errors
* Make $permission private and add a deprecated getter/setter
* Make $status private

Bug: T372181
Change-Id: If44b2256289d6bde9e9abb901d9dc145555c971f
2024-08-12 21:37:04 +02:00
Bartosz Dziewoński
298ec8382b PermissionsError: Replace use of legacy error arrays
Change-Id: I5493deb8b72f499ecd46b8093b5fffbb12e7c246
2024-08-09 13:53:27 +00:00
Umherirrender
6c41df61e9 tests: Use namespaced classes (1)
Changes to the use statements done automatically via script
Addition of missing use statement done manually

Change-Id: Iae45fa269363be8ee05c598ea6926514ce817762
2024-06-14 17:19:36 +00:00
Reedy
85396a9c99 tests: Fix @covers and @coversDefaultClass to have leading \
Change-Id: I5629f91387f2ac453ee4341bfe4bba310bd52f03
2024-02-16 22:43:56 +00:00
Tim Starling
5e30a927bc tests: Make some PHPUnit data providers static
Just methods where adding "static" to the declaration was enough, I
didn't do anything with providers that used $this.

Initially by search and replace. There were many mistakes which I
found mostly by running the PHPStorm inspection which searches for
$this usage in a static method. Later I used the PHPStorm "make static"
action which avoids the more obvious mistakes.

Bug: T332865
Change-Id: I47ed6692945607dfa5c139d42edbd934fa4f3a36
2023-03-24 02:53:57 +00:00
jenkins-bot
6a25db1206 Merge "Change $wgLang to use Message::*Param functions" 2023-01-28 00:31:50 +00:00
Umherirrender
abf2ea44e8 tests: Handle dynamic created properties on test classes
- Declare missing properties
- Remove unused or avoid set of properties
- Add AllowDynamicProperties

Bug: T314099
Change-Id: Ie631894f2ffbb616f6dd09851405d681f3eb8fcd
2023-01-13 21:03:42 +00:00
Umherirrender
f077ac60c0 Change $wgLang to use Message::*Param functions
Delay the formatting of numbers/lists when the message should be shown.
That allows to use the language of the user given to the message and
avoids global state by the global variable $wgLang or it use the global
state of Message class, which needs to be fixed later.

Change-Id: I015cea3a585a647e160b94d8ef30fad5d5df6cff
2022-09-26 19:12:15 +00:00
libraryupgrader
5357695270 build: Updating dependencies
composer:
* mediawiki/mediawiki-codesniffer: 36.0.0 → 37.0.0
  The following sniffs now pass and were enabled:
  * Generic.ControlStructures.InlineControlStructure
  * MediaWiki.PHPUnit.AssertCount.NotUsed

npm:
* svgo: 2.3.0 → 2.3.1
  * https://npmjs.com/advisories/1754 (CVE-2021-33587)

Change-Id: I2a9bbee2fecbf7259876d335f565ece4b3622426
2021-07-22 03:36:05 +00:00
Cindy Cicalese
f9e6c7b85b Allow PermissionError to be constructed with a PermissionStatus
Bug: T271504
Change-Id: I74d651c43cb67e928c627cb3812c6135232c99d8
2021-03-01 21:11:57 +00:00