Commit graph

28 commits

Author SHA1 Message Date
Siebrand Mazeland
5b119a0e44 Replace uses of join() by implode()
All of core uses implode() consistently now.

Change-Id: Iba50898c64c43f356d1caf8869f484e90d9ff651
2016-03-08 18:24:16 +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
493f4222cb phpcs: Assignment expression not allowed
Fix some "Assignment expression not allowed"

Found by tests:
https://integration.wikimedia.org/ci/job/mediawiki-core-phpcs/2736/consoleFull

Change-Id: I9bc2eff20a317a74671acd49749bb336a0fd9f67
2015-11-16 20:56:32 +00:00
umherirrender
cd80906d4a Change @return to start with type
MediaWiki default is "@return type Description", so set a type after
return and start the description with a capital letter. Also use the
more common spelling of boolean.

See http://phpdoc.org/docs/latest/references/phpdoc/tags/return.html for
more about @return

Change-Id: I4e5198822fe92836f9cef9918a9fc1a1a1e0a043
2014-08-20 20:35:41 +02:00
umherirrender
26837cd280 Cleanup some docs (tests)
- Swap "$variable type" to "type $variable"
- Fixed spacing inside docs
- Makes beginning of @param/@var/@throws in capital
- Changed some types to match the more common spelling

Change-Id: Ia041964250d8b7c0349d79dc9b131c5b8696e795
2014-08-11 20:06:52 +02:00
Siebrand Mazeland
80a8a8e85c Pass phpcs-strict on some test files (5/x)
Change-Id: I690645cd8a9b1165dcc8271b201c695ea9391226
2014-04-24 18:51:45 +02:00
umherirrender
092cd8ee31 Fixed some @params documentation (tests)
Swapped some "$var type" to "type $var" or added missing types
before the $var. Changed some other types to match the more common
spelling. Makes beginning of some text in captial.
Also added some missing @param.

Change-Id: Ic8aaf0a93796b97d0fa4617c1f86ff59f4b36131
2014-04-17 20:43:42 +02:00
umherirrender
725d9d125d Removed unneeded spaces and colons in @param and friends
Also swapped some "$var type" to "type $var" or added missing types
before the $var. Changed some other types to match the more common
spelling. Makes beginning of some text in captial.

Change-Id: Ic36c8c7820a6c2d603f1138130670c6bf6a1ca59
2014-04-08 16:02:49 +00:00
addshore
cad7b8368d General Cleanup of some Tests
Style Fixes, Comment fixes

Change-Id: I675d3f098e81709d5dfd928af6ca54589d3d5fad
2013-11-25 14:17:35 +00:00
umherirrender
5dbfd5bf80 Fixed spacing
- Removed trailing spaces in comments
- Removed multiple empty lines
- Removed space after object operator

Change-Id: I9fd3256ab490c7cd2034de3fd94e6be6e6d6d8f2
2013-11-21 18:52:25 +00:00
Siebrand Mazeland
59f6fd0199 Change EXIF to Exif
Per https://en.wikipedia.org/wiki/Exchangeable_image_file_format. Spotted
by Shirayuki and documented on
https://translatewiki.net/wiki/Thread:Support/About_MediaWiki:Sesp-property-exif-data/en

Change-Id: I92ba67ec60ccfe7a173d950593357b86792b8ed3
2013-05-10 13:51:06 +02:00
Siebrand Mazeland
791d0b2a98 Update code formatting
Change-Id: I16a9b42651f1cfb1a70dffbb67b7b83dfeb90d03
2013-04-26 14:21:20 +00:00
Siebrand Mazeland
9f77245218 Update formatting
4 of n.

Change-Id: I23e2409ce9eff14c3434154d236de83c93a92440
2013-02-14 14:10:38 +01:00
jeroendedauw
38c7f444e1 Use __DIR__ instead of dirname( __FILE__ )
We can now do this since we finally switched to PHP 5.3 for MW 1.20 and get rid of the silly dirname(__FILE__) stuff :)

Change-Id: Id9b2c9cd2e678197aa81c78adced5d1d31ff57b1
2012-08-27 21:45:00 +02:00
Antoine Musso
a5639ebd58 clean up whitespace / reindent 2011-12-08 13:02:34 +00:00
Sam Reed
90e74042b4 Fix comment blocks that start /* to /** 2011-10-11 18:30:50 +00:00
Chad Horohoe
4a293e11a3 Followup r93928: forgot to remove this 2011-08-04 22:34:26 +00:00
Chad Horohoe
e018780327 Fixes for r92251:
* Move Imagick check into getImageWriteMethod(), adjust exception catching. Previously this was bailing on the test if you have convert but not the PHP Imagick extension. Now all these tests are passing for me again.
* Rm unused member variable, whitespace, etc
2011-08-04 22:33:04 +00:00
Neil Kandalgaonkar
844ecc5cdb add maxWidth param 2011-08-02 00:36:38 +00:00
Bryan Tong Minh
0cdf9756e8 Add words.txt for us Windows users. This is a random selection of 1000 words from gnuwin32 miscfiles package
Fail more gracefully in RandomImageGenerator
2011-07-15 17:13:24 +00:00
Antoine Musso
cde767dd89 throw an exception on !is_executable( $wgExiv2Command ) 2011-07-01 18:34:50 +00:00
Neil Kandalgaonkar
7c44f1821b create images with orientation (had to use exiv2 hack, imagemagick not helpful) 2011-06-21 03:40:53 +00:00
Neil Kandalgaonkar
89cbb38778 fix invocation of static function 2011-06-18 03:36:44 +00:00
Neil Kandalgaonkar
5c540ab621 generate random triangles (so we can test EXIF orientation, eventually) 2011-06-17 23:26:45 +00:00
Neil Kandalgaonkar
4ae2a98e13 followup to r85654, move global declarations 2011-04-10 22:27:52 +00:00
Neil Kandalgaonkar
33d656ff88 also generate random SVG files 2011-04-07 23:32:36 +00:00
Paul Copperman
f7e6dfb4a3 Various fixes for PHPUnit tests:
* Block.php: Set mExpiry to the value we store in the database, so that Block::equals() returns true. Fixes BlockTest::testInitializerFunctionsReturnCorrectBlock.
* In Title::checkUserBlock(): Convert message parameters to plain strings to make strict comparisons work. Fixes TitlePermissionTest::testUserBlock().
* ApiBlock.php: Follow-Up r85166, add 'Confirm' parameter to data array. Fixes ApiBlockTest::testMakeNormalBlock().
* ApiQueryTest.php: Use $wgMetaNamespace instead of $wgSitename	to account for customizations.
* RandomImageGenerator.php: Use default value for constructor param to prevent fatals.
* ApiTestCaseUpload.php: 
** Fix undefined variable $fileName.
** Remove stray ini_set statements, they don't belong there. Especially ini_set( 'error_reporting', 1 ) will effectively disable all reporting, which makes errors hard to track.
* ArticleTablesTest.php: Put testbug14404() in group Broken, as the fix for the bug has been reverted in r83868.
2011-04-07 14:54:38 +00:00
Chad Horohoe
23f69f10ed Per wikitech-l discussion: Move tests from maintenance/tests/ to tests/. They're not strictly maintenance scripts, and some people want to do a selective checkout that doesn't include the tests. There's still debate on whether we should include these in the release downloads, but we had a pretty firm consensus to move this. 2010-12-14 16:26:35 +00:00