Commit graph

13 commits

Author SHA1 Message Date
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
Florian
c13605dba4 HTMLForm: Allow status object to have raw parameters
The status object, which can be returned after validating an HTMLForm,
can contain message objects. These message objects can be constructed
with the full feature set provided by Message, e.g. raw parameters.

The handling of these status objects in HTMLForm basically prevented
some features of the Message object in the status, as it parsed the
messages through the Parser, which does not recognize these raw
parameters as such and escapes them wrongly.

This behaviour is fixed with this change.

Bug: T240774
Change-Id: I152ec51f317799572bf6791e110cd72c42da82a0
2020-02-09 18:06:12 +01:00
Daimona Eaytoy
f5529400cc Stop using assertContains with string haystack
This was done automatically by replacing every assertContains with
string *needle*. Then verifying the results.

Bug: T192167
Change-Id: Id8cbbf3b01e948f80046714183cc299f86be21fd
2019-12-15 00:22:44 +00:00
James D. Forrester
83d76f4cb5 phpcs: Enable MediaWiki.Commenting.PhpunitAnnotations.ForbiddenExpectedException* and make pass
Change-Id: I63f97497714a32236268be6965c5e181dade6c58
2019-10-14 12:48:48 -07:00
Legoktm
4e35134f7a Revert "Separate MediaWiki unit and integration tests"
This reverts commit 0a2b996278.

Reason for revert: Broke postgres tests.

Change-Id: I27d8e0c807ad5f0748b9611a4f3df84cc213fbe1
2019-06-13 23:00:08 +00:00
Máté Szabó
0a2b996278 Separate MediaWiki unit and integration tests
This changeset implements T89432 and related tickets and is based on exploration
done at the Prague Hackathon. The goal is to identify tests in MediaWiki core
that can be run without having to install & configure MediaWiki and its dependencies,
and provide a way to execute these tests via the standard phpunit entry point,
allowing for faster development and integration with existing tooling like IDEs.

The initial set of tests that met these criteria were identified using the work Amir did in
I88822667693d9e00ac3d4639c87bc24e5083e5e8. These tests were then moved into a new subdirectory
under phpunit/ and organized into a separate test suite. The environment for this suite
is set up via a PHPUnit bootstrap file without a custom entry point.

You can execute these tests by running:
$ vendor/bin/phpunit -d memory_limit=512M -c tests/phpunit/unit-tests.xml

Bug: T89432
Bug: T87781
Bug: T84948
Change-Id: Iad01033a0548afd4d2a6f2c1ef6fcc9debf72c0d
2019-06-13 22:56:31 +02:00
Thiemo Kreuz (WMDE)
f6e51e5274 thiemowmde's legal name changed
I was a co-author only, and my contribution was not really
noteworthy, so I choose to remove the outdated name (in this
case only).

Change-Id: I9d9592d5b114adae633f6a4bdac2dd60f329bd7a
2018-07-24 06:07:38 +00:00
David Barratt
d609da624b
Add a method to HTMLForm that allows the preText to be accessed externally.
Currently there is no way to access the preText outside of an HTMLForm. Adding
a getPreText method to HTMLForm so the preText is accessible.

Bug: T199115
Change-Id: I937028e7025b4a7b5d333e9bf5a25920f6a88316
2018-07-09 10:42:19 -04:00
Kunal Mehta
e0193327bd Fix MediaWiki.Commenting.LicenseComment.InvalidLicenseTag errors
Change-Id: I936c3f5fca1a0061f215e80469f5d882cb32ee29
2018-05-23 16:23:42 -07:00
Umherirrender
69dbaf3f88 build: Updating mediawiki/mediawiki-codesniffer to 17.0.0
Change-Id: Ib494b47c54fe6354d166055b1e1b31d3583bb992
2018-03-29 21:53:10 +02:00
Fomafix
04ff65fc69 Simplify autocomplete attribute in HTMLForm
Follows-up 7489a3e8

Change-Id: Ifb17c88e39df7031054b3bee83772172c64d0a6b
2017-12-28 16:41:39 +01:00
Kunal Mehta
01f7176c8b Add @covers tags to HTMLForm test
Change-Id: I41cc4867b071ee9a58a43760fc4a8b301cda558e
2017-12-27 17:47:17 +00:00
Gergő Tisza
e3d7978bc6 Enforce calling HTMLForm::prepareForm before displayForm
Bug: T133163
Change-Id: Idd5d117cb0dd65c195019dcd321cd4bf9024b426
2016-04-27 20:00:06 +01:00