Commit graph

14 commits

Author SHA1 Message Date
thiemowmde
32d214dd6d Drop duplicate test cases and @dataProviders from tests
A single test function can have multiple @dataProviders. No problem.

A @dataProvider can also be used by multiple test functions. No
problem. No need to duplicate such large pieces of code when it's
identical anyway.

Change-Id: I5aea36304ec2d1666ff2334ba883df07a70c15c5
2024-07-19 10:18:31 +00:00
Reedy
85396a9c99 tests: Fix @covers and @coversDefaultClass to have leading \
Change-Id: I5629f91387f2ac453ee4341bfe4bba310bd52f03
2024-02-16 22:43:56 +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
Derick Alangi
175832a8e9 Migrate usage of setMwGlobals() to overrideConfigValue(s)
Change-Id: I49d97864d8f9d8cadf01b0c0dc653fbac4ca9e94
2022-08-01 06:16:22 +01:00
EpicPupper
6abc28230b Unify how the term "undelete" is used in the undelete UI
Amend DeleteLogFormatterTest phpunit test with new string

Bug: T307181
Change-Id: I367b78068c8177505651c6d87ce668b36e1ca651
2022-05-16 13:31:01 +00:00
Umherirrender
7359c6bda9 Allow DeleteLogFormatter to work with pre-T20361 (April 2009) log rows
The i18n part of T20361 / ec0dd5b adds new log parameter,
logs from before the changes are needed to work with the formatter.

Bug: T289806
Change-Id: I096bc14373cbe038671fc33f651af7e005998a3b
2021-12-04 19:45:51 +01:00
rxy
0b91327754 Add permission check for user is permitted to view the log type
Note: formatter patch only

Note: cherry-picked I064f563cb here as well

Bug: T222038
Change-Id: I1c4e57a513e3a0e616b862a5b9d684f463ad9981
2019-07-25 20:32:37 +00:00
SBassett
ec104811c6 Revert "Fix testsuites for LogFormatter"
This reverts commit d0c2da8261.

Reason for revert: Original patch set appeared to work then began failing multiple CI builds post-merge.  Simply reverting for now due for T226293.

Big: T226293
Change-Id: I3e33300cecfe87926fcb8851689d67c3b1258b0f
2019-06-22 12:25:33 +00:00
rxy
d0c2da8261 Fix testsuites for LogFormatter
Change-Id: I064f563cb54a50c3292b1f9e24b0bb467f69af9b
2019-06-21 21:55:51 +00:00
Brad Jorsch
144ebd06c7 DeleteLogFormatter: Handle missing ofield/nfield
ofield and nfield may be missing from old log entries. Take that into
account when processing.

Bug: T224815
Change-Id: I06dda3106bab9980f6fa7d515542e94a91c17f64
2019-06-12 23:33:45 +00:00
Kunal Mehta
c368a4313b Add @covers tags to logging tests
Change-Id: Ibb14291a75423ddbb7502a5a0ee24ff0c554a876
2017-12-24 23:29:00 -08:00
umherirrender
6971569512 Move count of revisions/files out of undelete log comment
The log comment on undelete contains a hint about the count of restored
files and/or revisions.
Move this text out of the comment to allow longer comments. Also makes
this information readable inside the api.

This is only for new log entries. Old entries will still show the hint
from the comment and no data in the api.

Change-Id: I9e30eb1271656bb81259a408210e9a282e949c57
2017-04-08 05:46:45 +00:00
Kunal Mehta
6e9b4f0e9c Convert all array() syntax to []
Per wikitech-l consensus:
 https://lists.wikimedia.org/pipermail/wikitech-l/2016-February/084821.html

Notes:
* Disabled CallTimePassByReference due to false positives (T127163)

Change-Id: I2c8ce713ce6600a0bb7bf67537c87044c7a45c4b
2016-02-17 01:33:00 -08:00
umherirrender
eeea90d2b1 Add unit tests for all LogFormatters
Test the LogFormatter by passing old and new database rows to it.
The text shown on Special:Log and the api result returned by
list=logevents is tested.

Change-Id: Icfcba506f4fa3010cdaf973aa2df23b6e92c25e4
2015-05-03 21:58:00 +00:00