Commit graph

13 commits

Author SHA1 Message Date
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
daniel
0dec104bc0 Deferred updates: remove Title from method signatures.
This allows deferred update tasks to be constructed with a PageIdentity
rather than a Title instance.

Bug: T278459
Change-Id: Ifa2888fdef9ecc97f5bf09ae0b3fa7be48a0e9ef
2021-05-11 11:17:02 +02:00
DannyS712
208a84d5ff SearchUpdateTest: remove unused MockSearch class
Follow-up: I5677041169402014f1afc1a9012460c760ca24b6
Change-Id: I3161abe7190a02e85c65bed2f19a45285ee3c888
2021-03-11 19:25:05 +00:00
addshore
959bc315f2 MediaWikiTestCase to MediaWikiIntegrationTestCase
The name change happened some time ago, and I think its
about time to start using the name name!
(Done with a find and replace)

My personal motivation for doing this is that I have started
trying out vscode as an IDE for mediawiki development, and
right now it doesn't appear to handle php aliases very well
or at all.

Change-Id: I412235d91ae26e4c1c6a62e0dbb7e7cf3c5ed4a6
2020-06-30 17:02:22 +01:00
Max Semenik
48a323f702 tests: Add explicit return type void to setUp() and tearDown()
Bug: T192167
Depends-On: I581e54278ac5da3f4e399e33f2c7ad468bae6b43
Change-Id: I3a21fb55db76bac51afdd399cf40ed0760e4f343
2019-10-30 14:31:22 -07:00
David Causse
bc0de57e75 Simplify SearchUpdate constructor and hard deprecate some param types
Change-Id: I5677041169402014f1afc1a9012460c760ca24b6
2019-08-01 17:24:42 +02:00
Aaron Schulz
d16fb6515b search: refactor DatabaseSearch to take a load balancer instance
Also make the update() methods of the subclasses use DB_MASTER as they
should. This avoids read-only errors.

In addition, avoid passing a dummy argument of null in some cases
within SearchEngineFactory::create(). Fix some dynamic calls to
static methods too.

Change-Id: Id94f34994b0f9c18e23ef30cb2fe895e6dedd09c
2019-06-26 03:03:37 +00:00
Kunal Mehta
b6b10bb58f Require ClassMatchesFilename sniff to pass for most of tests/
phpunit-patch-coverage assumes that the filename matches the classname
as a performance optimization. And for most test cases, this is true. We
should enforce this with PHPCS, mostly to help developers not make
mistakes.

Test cases that have mock classes will need to ensure that the test case
class that matches the filename comes first, since that's the only class
the sniff will look at.

Tests in GlobalFunctions/ and maintenance/ are still exempted for now,
since they don't match yet.

Change-Id: Iede341504290f5ba2da1c81908069ba9d465600f
2019-01-29 23:57:12 -08:00
James D. Forrester
1e9c361960 tests: Replace implicit Bugzilla bug numbers with Phab ones
It's unreasonable to expect newbies to know that "bug 12345" means "Task T14345"
except where it doesn't, so let's just standardise on the real numbers.

Change-Id: I46261416f7603558dceb76ebe695a5cac274e417
2017-02-21 02:14:34 +00:00
Stanislav Malyshev
34b02d87ac Convert SearchEngine to service containers
Change-Id: Icef1ecbed3d831557e0256fdfa53743b194007cc
2016-04-25 16:25:17 -07:00
Kunal Mehta
8a10113bd3 SearchUpdateTest does not require database access
Change-Id: I2d8515215f52216f463a2b3536bea0e24b7bf5ce
2015-03-26 17:18:12 -07:00
Robert Hoenig
43b88b11b3 Clarifies the meaning of the function which tests the bug T34712
Change-Id: I17922b9bc6ac2ce5fef7aebc27020874d349f507
2015-01-01 18:16:42 -06:00
umherirrender
1d8b52fbfd Move Test files under same folder structure where class is (/includes/)
Change-Id: I95f1aa6f0ed2cc3306aa6e588a11f359854315c1
2014-12-16 21:56:44 +01:00
Renamed from tests/phpunit/includes/search/SearchUpdateTest.php (Browse further)