From 3e1337b469b6a3c05647e1a17f61c20b41ac3132 Mon Sep 17 00:00:00 2001 From: Chad Horohoe Date: Fri, 13 Aug 2010 14:36:59 +0000 Subject: [PATCH] Fix #1 for r70970: Make UploadFromUrlTestSuite initialize a User instead of StubUser --- includes/specials/SpecialVersion.php | 35 +++++++------------- languages/messages/MessagesEn.php | 16 +++++++++ maintenance/language/messages.inc | 2 ++ maintenance/tests/UploadFromUrlTestSuite.php | 2 +- 4 files changed, 31 insertions(+), 24 deletions(-) diff --git a/includes/specials/SpecialVersion.php b/includes/specials/SpecialVersion.php index cca95a0e08..3c6ef10d79 100644 --- a/includes/specials/SpecialVersion.php +++ b/includes/specials/SpecialVersion.php @@ -70,33 +70,22 @@ class SpecialVersion extends SpecialPage { * @return string */ private static function getMediaWikiCredits() { + global $wgLang; + + $authorList = array( 'Magnus Manske', 'Brion Vibber', 'Lee Daniel Crocker', + 'Tim Starling', 'Erik Möller', 'Gabriel Wicke', 'Ævar Arnfjörð Bjarmason', + 'Niklas Laxström', 'Domas Mituzas', 'Rob Church', 'Yuri Astrakhan', + 'Aryeh Gregor', 'Aaron Schulz', 'Andrew Garrett', 'Raimond Spekking', + 'Alexandre Emsenhuber', 'Siebrand Mazeland', 'Chad Horohoe', 'others' + ); $ret = Xml::element( 'h2', array( 'id' => 'mw-version-license' ), wfMsg( 'version-license' ) ); // This text is always left-to-right. - $ret .= '
'; + $ret .= '
'; $ret .= "__NOTOC__ - This wiki is powered by '''[http://www.mediawiki.org/ MediaWiki]''', - copyright © 2001-2010 Magnus Manske, Brion Vibber, Lee Daniel Crocker, - Tim Starling, Erik Möller, Gabriel Wicke, Ævar Arnfjörð Bjarmason, - Niklas Laxström, Domas Mituzas, Rob Church, Yuri Astrakhan, Aryeh Gregor, - Aaron Schulz, Andrew Garrett, Raimond Spekking, Alexandre Emsenhuber, - Siebrand Mazeland, Chad Horohoe and others. - - MediaWiki is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - MediaWiki is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received [{{SERVER}}{{SCRIPTPATH}}/COPYING a copy of the GNU General Public License] - along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - or [http://www.gnu.org/licenses/old-licenses/gpl-2.0.html read it online]. - "; + " . wfMsg( 'version-poweredby-credits', date( 'Y' ), + $wgLang->listToText( $authorList ) ) . "\n + " . wfMsg( 'version-license-info' ); $ret .= '
'; return str_replace( "\t\t", '', $ret ) . "\n"; diff --git a/languages/messages/MessagesEn.php b/languages/messages/MessagesEn.php index 674972af0b..5359c7733e 100644 --- a/languages/messages/MessagesEn.php +++ b/languages/messages/MessagesEn.php @@ -4242,6 +4242,22 @@ You can also [[Special:Watchlist/edit|use the standard editor]].', 'version-version' => '(Version $1)', 'version-svn-revision' => '(r$2)', # only translate this message to other languages if you have to change it 'version-license' => 'License', +'version-poweredby-credits' => "This wiki is powered by '''[http://www.mediawiki.org/ MediaWiki]''', copyright © 2001-$1 $2.", // $1 is the current year, $2 is the list of authors +'version-license-info' => "MediaWiki is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + MediaWiki is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received [{{SERVER}}{{SCRIPTPATH}}/COPYING a copy of the GNU General Public License] + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA + or [http://www.gnu.org/licenses/old-licenses/gpl-2.0.html read it online]. + ", 'version-software' => 'Installed software', 'version-software-product' => 'Product', 'version-software-version' => 'Version', diff --git a/maintenance/language/messages.inc b/maintenance/language/messages.inc index ee8cfedd48..ab7e69b302 100644 --- a/maintenance/language/messages.inc +++ b/maintenance/language/messages.inc @@ -3137,6 +3137,8 @@ $wgMessageStructure = array( 'version-version', 'version-svn-revision', 'version-license', + 'version-poweredby-credits', + 'version-license-info', 'version-software', 'version-software-product', 'version-software-version', diff --git a/maintenance/tests/UploadFromUrlTestSuite.php b/maintenance/tests/UploadFromUrlTestSuite.php index 06bd99779e..a439fd9b4a 100644 --- a/maintenance/tests/UploadFromUrlTestSuite.php +++ b/maintenance/tests/UploadFromUrlTestSuite.php @@ -46,7 +46,7 @@ class UploadFromUrlTestSuite extends PHPUnit_Framework_TestSuite $parserMemc =& wfGetParserCacheStorage(); //$wgContLang = new StubContLang; - $wgUser = new StubUser; + $wgUser = new User; $wgLang = new StubUserLang; $wgOut = new StubObject( 'wgOut', 'OutputPage' ); $wgParser = new StubObject( 'wgParser', $wgParserConf['class'], array( $wgParserConf ) ); -- 2.20.1