MediaWiki  1.23.2
Todo List
Member ApiQueryAllPagesTest::testBug25702 ()
give this test a real name explaining what is being tested here
Class ApiWatchTest
This test suite is severly broken and need a full review
Class Article
Move and rewrite code to an Action class
Member Article::confirmDelete ( $reason)
FIXME: Move to another file?
Member Article::fetchContentObject ()
When is this null?
Member Article::showDiffPage ()
Make protected
Member ArticleTablesTest::testbug14404 ()
give this test a real name explaining what is being tested here
Member AtomFeed::formatTime ( $ts)
document
Member BackupDumper::backupDb ()
Fixme: the –server parameter is currently not respected, as it doesn't seem terribly easy to ask the load balancer for a particular connection by name.
File Benchmarker.php
Report PHP version, OS ..
Member BitmapHandler::getClientScalingThumbnailImage ( $image, $scalerParams)
FIXME: No rotation support
Class BitmapMetadataHandler
Other image formats.
Member BitmapMetadataHandler::Tiff ( $filename)
Add XMP support, so this function actually makes sense to put here.
Member Block::__construct ( $address='', $user=0, $by=0, $reason='', $timestamp=0, $auto=0, $expiry='', $anonOnly=0, $createAccount=0, $enableAutoblock=0, $hideName=0, $blockEmail=0, $allowUsertalk=0, $byText='')
FIXME: Don't know what the best format to have for this constructor is, but fourteen optional parameters certainly isn't it.
Member Block::getTargetAndType ()
FIXME: This should be an integral part of the Block member variables
Member CacheTime::isDifferentRevision ( $id)
We always return false if $this->getCacheRevisionId() is null; this prevents invalidating the whole parser cache when this change is deployed. Someday that should probably be changed.
Class Category
Move some stuff from CategoryPage.php to here, and use that.
Member Categoryfinder::seed ( $article_ids, $categories, $mode='AND')
FIXME: $categories/$mode
File cdb.php
document
Class ChangesListSpecialPage
Way too many public functions, most of them should be protected
Member ChangesListSpecialPage::getExtraOptions ( $opts)

This should handle options returned by getDefaultOptions().

Not called by anything, should be called by something… doHeader() maybe?

Member ChangesListSpecialPage::makeLegend (IContextSource $context)

This should not be static, then we can drop the parameter

Not called by anything, should be called by doHeader()

Class CleanUpTest

covers tags, will be UtfNormal::cleanUp once the below is resolved

split me into test methods and providers per the below comment

Member CleanUpTest::doTestBytes ( $head, $tail)
document
Member CleanUpTest::doTestDoubleBytes ( $head, $tail)
document
Member CleanUpTest::doTestTripleBytes ( $head, $tail)
document
Member CleanUpTest::testAllBytes ()
document
Member CleanUpTest::testAscii ()
document
Member CleanUpTest::testBomRegression ()
document
Member CleanUpTest::testChunkRegression ()
document
Member CleanUpTest::testDoubleBytes ()
document
Member CleanUpTest::testForbiddenRegression ()
document
Member CleanUpTest::testHangulRegression ()
document
Member CleanUpTest::testInterposeRegression ()
document
Member CleanUpTest::testLatin ()
document
Member CleanUpTest::testLatinNormal ()
document
Member CleanUpTest::testNull ()
document
Member CleanUpTest::testOverlongRegression ()
document
Member CleanUpTest::testSurrogateRegression ()
document
Member CleanUpTest::testTripleBytes ()
document
Member CleanUpTest::XtestAllChars ()
document
File CologneBlue.php
document
Member CompressOld::compressOldPages ( $start=0, $extdb='')
document
Member CompressOld::compressPage ( $row, $extdb)
document
Member CompressOld::LS_INDIVIDUAL
document
Member Content::getTextForSearchIndex ()

Test that this actually works

Make sure this also works with LuceneSearch / WikiSearch

Member Content::getWikitextForTransclusion ()

Allow native handling, bypassing wikitext representation, like for includable special pages.

Allow transclusion into other content models than Wikitext!

Used in WikiPage and MessageCache to get message text. Not so nice. What should we use instead?!

Member ContribsPager::formatRow ( $row)
This would probably look a lot nicer in a table.
Member ConverterRule::hasRules ()
FIXME: code this function :)
Member Cookie::validateCookieDomain ( $domain, $originDomain=null)

fixme fails to detect 3-letter top-level domains

fixme fails to detect 2-letter top-level domains for single-domain use (probably not a big problem in practice, but there are test cases)

Member CoreTagHooks::gallery ( $content, $attributes, $parser)
break Parser::renderImageGallery out here too.
Member DatabaseBase::selectDB ( $db)
Explain what exactly will fail if this is not overridden.
Member DatabaseInstaller::$parent
Naming this parent is confusing, 'installer' would be clearer.
Member DatabaseMysqlBase::masterPosWait (DBMasterPos $pos, $timeout)
Return values for this and base class are rubbish
Member DatabasePostgres::insertSelect ( $destTable, $srcTable, $varMap, $conds, $fname=__METHOD__, $insertOptions=array(), $selectOptions=array())
FIXME: Implement this a little better (seperate select/insert)?
Member DatabaseSqlite::implicitGroupby ()
Check if it should be true like parent class
Member DatabaseSqliteTest::testUpgrades ()
Currently only checks list of tables
Class DateFormatter
preferences, OutputPage
Member DateFormatter::getMonthRegex ()
document
Member DateFormatter::makeIsoYear ( $year)
document
Member DateFormatter::makeNormalYear ( $iso)
document
Member DeletedContribsPager::formatRow ( $row)
This would probably look a lot nicer in a table.
Member DeletedContributionsPage::getSubTitle ( $userObj)
FIXME: Almost the same as contributionsSub in SpecialContributions.php. Could be combined.
File deleteOrphanedRevisions.php
More efficient cleanup of text records
Class Diff
document
Class DifferenceEngine
document
Member DifferenceEngine::generateTextDiffBody ( $otext, $ntext)
move this to TextDifferenceEngine, make DifferenceEngine abstract. At some point.
Class DifferenceEngineTest
tests for the rest of DifferenceEngine!
Class DiffFormatter
document
Class DiffOp
document
Class DiffOpAdd
document
Class DiffOpChange
document
Class DiffOpCopy
document
Class DiffOpDelete
document
File dumpMessages.php
Make this more useful, right now just dumps $wgContLang
Member EditPageTest::testCreatePage ()
split into a dataprovider and test method @covers EditPage
Member Exif::__construct ( $file, $byteOrder='')
FIXME: The following are broke: SubjectArea. Need to test the more obscure tags. DigitalZoomRatio = 0/0 is rejected. need to determine if that's valid. Possibly should treat 0/0 = 0. need to read exif spec on that.
Member ExifBitmapHandler::getRotationForExif ( $data)
FIXME: Orientation can include flipping as well; see if this is an issue!
Class ExifRotationTest
covers tags
Member FauxResponse::setcookie ( $name, $value, $expire=0, $options=null)
document.
Class FormOptions
This badly needs some examples and tests :) The usage in SpecialRecentchanges class is a good ersatz in the meantime.
Member GIFHandler::getImageArea ( $image)
Add unit tests
Member H
document (needs one-sentence top-level class description).
Member H
document (needs one-sentence top-level class description).
Member HistoryPager::historyLine ( $row, $next, $notificationtimestamp=false, $latest=false, $firstInList=false)
document some more, and maybe clean up the code (some params redundant?)
Member Html::inlineScript ( $contents)
do some useful escaping as well, like if $contents contains literal "</script>" or (for XML) literal "]]>".
Class HTMLForm
Document 'section' / 'subsection' stuff
Member HTMLForm::displaySection ( $fields, $sectionName='', $fieldsetIDPrefix='', &$hasUserVisibleFields=false)
Document
Member HTMLForm::setMessagePrefix ( $p)
Currently only used for the "<fieldset>" legend on forms with multiple sections; should be used elsewhere?
Member HTMLForm::setSubmitID ( $t)
FIXME: Integrity of $t is not validated
Class HTMLSelectAndOtherField
FIXME: If made 'required', only the text field should be compulsory.
Member Http::isValidURI ( $uri)
FIXME this is wildly inaccurate and fails to actually check most stuff
Class HttpStatus
document
Class HWLDFWordAccumulator
document
File IEContentAnalyzer.php
Define the exact license of this file.
Class IEUrlExtensionTest
tests below for findIE6Extension should be split into...
Member ImagePage::makeMetadataTable ( $metadata)
FIXME: Bad interface, see note on MediaHandler::formatMetadata().
Class ImportStreamSource
document (e.g.
Class ImportStringSource
document (e.g.
Member IORMTable::getFields ()
Get rid of the id field. Every row instance needs to have one so this is just causing hassle at various locations by requiring an extra check for field name.
Member IPTC::timeHelper ( $date, $time, $c)
Potentially this should also capture the timezone offset.
Class IPTest
Test methods in this call should be split into a method and a dataprovider.
Member IPTest::testSanitizeIP ()
Most probably incomplete
Class JavaScriptContentHandler
make ScriptContentHandler base class, do highlighting stuff there?
Member JavaScriptContentTest::dataIsCountable ()

Test needs database!

Test needs database!

Member JavaScriptMinifierTest::testBug32548Exponent ( $num)
give this test a real name explaining what is being tested here
Class JpegMetadataExtractorTest
Could use a test of extended XMP segments.
Member Language::convertHtml ( $text, $isTitle=false)
this should get integrated somewhere sane
Member Language::formatExpiry ( $expiry, $format=true)
FIXME: why are we returnings DBMS-dependent strings???
Member Language::formatNum ( $number, $nocommafy=false)
check if it's viable to use localeconv() for the decimal separator thing.
Member Language::formatTimePeriod ( $seconds, $format=array())
Document
Member Language::sprintfDate ( $format, $ts, DateTimeZone $zone=null)
handling of "o" format character for Iranian, Hebrew, Hijri & Thai?
Member Language::translateBlockExpiry ( $str)
Maybe translate block durations.
Member LanguageAr::normalize ( $s)
FIXME: This is language-specific for now only to avoid the negative performance impact of enabling it for all languages.
Member LanguageArTest::testFormatNum ()
split into a test and a dataprovider
Member LanguageMl::normalize ( $s)
FIXME: This is language-specific for now only to avoid the negative performance impact of enabling it for all languages.
Member LanguageNlTest::testFormatNum ()
split into a test and a dataprovider
File LanguageSrTest.php
methods in test class should be tidied:
  • Should be split into separate test methods and data providers
  • Tests for LanguageConverter and Language should probably be separate..
File LanguageUzTest.php
methods in test class should be tidied:
  • Should be split into separate test methods and data providers
  • Tests for LanguageConverter and Language should probably be separate..
Member LanguageYue::segmentByWord ( $string)
FIXME: Only do this for Han characters...
Member LanguageZh_hans::segmentByWord ( $string)
FIXME: Only do this for Han characters...
Class Linker
: turn this into a legacy interface for HtmlPageLinkRenderer and similar services.
Member Linker::formatLinksInComment ( $comment, $title=null, $local=false)
FIXME: Doesn't handle sub-links as in image thumb texts like the main parser
Member Linker::makeMediaLinkFile (Title $title, $file, $html='')
Handle invalid or missing images better.
Class LinkFilter
implement the filter. Currently these are just some functions to help maintenance/cleanupSpam.php remove links to a single specified domain. The next thing is to implement functions for checking a given page against a big list of domains.
Member LinkSearchPage::setPageLinkRenderer (PageLinkRenderer $linkRenderer)
: query logic and rendering logic should be split and also injected
Class LinksUpdate
document (e.g. one-sentence top-level class description).
Class LoadBalancer
document
Member LocalFile::migrateThumbFile ( $thumbName)
Do we still care about this? Perhaps a maintenance script can be made instead.
Class LocalFileTest
Split tests into providers and test methods
Member LogPage::getTitleLink ( $type, $lang, $title, &$params)
Document
Member LogPage::logHeader ( $type)
handle missing log types
File MagicVariableTest.php
covers tags
Member MagicWord::replaceMultiple ( $magicarr, $subject, &$result)
Should this be static? It doesn't seem to be used at all
Class MappedDiff
document, bad name.
File mcc.php
document
Member MediaHandler::formatMetadata ( $image)
FIXME: This interface is not very flexible.
Member MediaHandlerTest::testFitBoxWidth ()
split into a dataprovider and test method
Member MediaWikiTitleCodec::splitTitleString ( $text, $defaultNamespace=NS_MAIN)

: this method is only exposed as a temporary measure to ease refactoring. It was copied with minimal changes from Title::secureAndSplit().

: This method should be split up and an appropriate interface defined for use by the Title class.

File Modern.php
document
Class ModernTemplate
document
File MonoBook.php
document
Class MonoBookTemplate
document
Class MWDebug
Profiler support
Member MWDebug::log ( $str)
Add support for passing objects
File mwdocgen.php
document
Member MWHttpRequest::setData ( $args)
overload the args param
Class MWNamespaceTest
covers tags @FIXME this test file is a mess
Member MWNamespaceTest::testCanTalk ()

Implement testGetCanonicalNamespaces().

Implement testGetCanonicalName().

Implement testGetCanonicalIndex().

Implement testGetValidNamespaces().

Member MWNamespaceTest::testEquals ()
Implement testExists().
Member MWNamespaceTest::testIsCapitalizedWithWgCapitalLinkOverrides ()
split groups of assertions in autonomous testing functions @covers MWNamespace::isCapitalized
Member MWNamespaceTest::testIsMovable ()
Write more texts, handle $wgAllowImageMoving setting @covers MWNamespace::isMovable
File MWTerm.php
Fixme: Make this more generic
Member NamespaceConflictChecker::checkAll ( $fix, $suffix='')
Document
Member NamespaceConflictChecker::checkNamespace ( $ns, $name, $fix, $suffix='')
Document
Member NamespaceConflictChecker::checkPrefix ( $key, $prefix, $fix, $suffix='')
Do this for real
Member Orphans::checkWidows ( $fix)
DON'T USE THIS YET! It will remove entries which have children, but which aren't properly attached (eg if page_latest is bogus but valid revisions do exist)
Class OutputPage

FIXME: Another class handles sending the whole page to the client.

document

Member OutputPage::$mInlineMsg
FIXME: Is this still used ?
Member OutputPage::addVaryHeader ( $header, $option=null)
FIXME: Document the $option parameter; it appears to be for X-Vary-Options but what format is acceptable?
Member OutputPage::readOnlyPage ( $source=null, $protected=false, $reasons=array(), $action=null)
Needs to be split into multiple functions.
Class OutputPageTest
factor tests in this class into providers and test methods
Member PageArchive::listFiles ()
Does this belong in Image for fuller encapsulation?
Member PageLinkRenderer::getPageUrl (TitleValue $page, $params=array())
expand this to cover the functionality of Linker::linkUrl
Member PageLinkRenderer::renderHtmlLink (TitleValue $page, $text=null)
expand this to cover the functionality of Linker::link
Class ParserCache
document
Member ParserCache::getKey ( $article, $popts, $useOutdated=true)
Document parameter $useOutdated
File parserTest.inc

Make this more independent of the configuration (and if possible the database)

document

Member PostgresUpdater::getCoreUpdateList ()
FIXME: Postgres should use sequential updates like Mysql, Sqlite and everybody else.
Class Profiler
document
Class ProfilerSimple
document methods (?)
Class ProfilerSimpleTrace
document methods (?)
Class ProtectedPagesPager
document
Class ProtectedTitlesPager
document
File rebuildrecentchanges.php
Document
File rebuildtextindex.php
document
Member RecentChangeTest::assertIRCComment ( $expected, $type, $action, $params, $comment=null, $msg='')
Emulate these edits somehow and extract
Class Revision
document
Member Revision::getText ( $audience=self::FOR_PUBLIC, User $user=null)
Replace usage in core
Member Revision::newFromArchiveRow ( $row, $overrides=array())
FIXME: Should be a subclass for RevisionDelete. [TS]
Member Sanitizer::escapeClass ( $class)
For extra validity, input should be validated UTF-8.
Member Sanitizer::mergeAttributes ( $a, $b)
implement merging for other attributes such as style
Member Sanitizer::normalizeAttributeValue ( $text)
Remove, unused?
Member Sanitizer::validateAttributes ( $attribs, $whitelist)

Check for legal values where the DTD limits things.

Check for unique id attribute :P

Member Sanitizer::validateTagAttributes ( $attribs, $element)

Check for legal values where the DTD limits things.

Check for unique id attribute :P

Class SanitizerTest
Tests covering decodeCharReferences can be refactored into a single method and dataprovider.
Member SearchEngine::getTextFromContent (Title $t, Content $c=null)
This isn't ideal, we'd really like to have content-specific handling here
Class SearchEngineDummy
FIXME: Dummy class should probably try something at least mildly useful, such as a LIKE search through titles.
Member SearchMssql::parseQuery ( $filteredText, $fulltext)
document
Class SearchResult
FIXME: This class is horribly factored.
Member SearchUpdateTest::testBug32712 ()
give this test a real name explaining what is being tested here
File Setup.php
UGLY UGLY
Member SideBarTest::assertSideBar ( $expected, $text, $message='')
this assert method to should be converted to a test using a dataprovider..
Member Skin::setupSkinUserCss (OutputPage $out)
delete
Class SkinCologneBlue
document
Class SkinModern
document
Class SkinMonoBook
document
Class SkinTemplate
Needs some serious refactoring into functions that correspond to the computations individual esi snippets need. Most importantly no body parsing for most of those of course.
Member SpecialBlock::getSuggestedDurations ( $lang=null)
FIXME: This uses a rather odd syntax for the options, should it be converted to the standard "**<duration>|<displayname>" format?
Class SpecialBookSources
Validate ISBNs using the standard check-digit method
Member SpecialCategories::setPageLinkRenderer (PageLinkRenderer $linkRenderer)
: the pager should also be injected, and de-coupled from the rendering logic.
Member SpecialContributions::contributionsSub ( $userObj)
FIXME: Almost the same as getSubTitle in SpecialDeletedContributions.php. Could be combined.
Class SpecialCreateAccount
FIXME: This (and the rest of the login frontend) needs to die a horrible painful death
Class SpecialPage
Turn this into a real ContextSource
Member SpecialPreferencesTest::testBug41337 ()
give this test a real name explaining what is being tested here
Member SpecialRevisionDelete::addUsageText ()
FIXME: Wikimedia-specific policy text
Member SpecialUploadStash::outputFileHeaders ( $contentType, $size)
Unsure about encoding as binary; if we received from HTTP perhaps we should use that encoding, concatted with semicolon to mimeType as it usually is.
File SpecialWhatlinkshere.php
Use some variant of Pager or something; the pagination here is lousy.
Member StatusTest::testGetHtml (Status $status, $wikitext, $html)
test long and short context messages generated through this method this can not really be done now due to use of $this->getWikiText using wfMessage()->plain() It is possible to mock such methods but only if namespaces are used
Member StatusTest::testGetMessage (Status $status, $expectedParams=array(), $expectedKey)
test long and short context messages generated through this method
Member StatusTest::testGetWikiText (Status $status, $wikitext, $html)
test long and short context messages generated through this method this can not really be done now due to use of wfMessage()->plain() It is possible to mock such methods but only if namespaces are used
Class StripState
document, briefly.
Class TableDiffFormatter
document
Member TextContentTest::dataIsCountable ()

Test needs database! Should be done by a test class in the Database group.

Test needs database! Should be done by a test class in the Database group.

Member Title::getBrokenLinksFrom ()
check if needed (used only in SpecialBrokenRedirects.php, and should use redirect table in this case)
Member Title::getTitleInvalidRegex ()
: move this into MediaWikiTitleCodec
Member Title::getUserPermissionsErrors ( $action, $user, $doExpensiveQueries=true, $ignoreErrors=array())
FIXME: This does not check throttles (User::pingLimiter()).
Member TitleFormatter::getNamespaceName ( $namespace, $text)
Move this to a separate interface
Member TitlePermissionTest::testActionPermissions ()
This test method should be split up into separate test methods and data providers
Member TitlePermissionTest::testCssAndJavascriptPermissions ()
This test method should be split up into separate test methods and data providers
Member TitlePermissionTest::testPageRestrictions ()
This test method should be split up into separate test methods and data providers
Member TitlePermissionTest::testQuickPermissions ()
This test method should be split up into separate test methods and data providers
Member TitlePermissionTest::testSpecialsAndNSPermissions ()
This test method should be split up into separate test methods and data providers
Member TitleTest::testBug31100FixSpecialName ( $text, $expectedParam)
give this test a real name explaining what is being tested here
Member TitleTest::testGetSubpageText ( $title, $expected, $msg='')
Handle $wgNamespacesWithSubpages cases @dataProvider provideSubpageTitleCases @covers Title::getSubpageText
Member TitleTest::testSecureAndSplit ()
This method should be split into 2 separate tests each with a provider
Class UncategorizedImagesPage
FIXME: Use an instance of UncategorizedPagesPage or something
Class UncategorizedPagesPage
FIXME: Make $requestedNamespace selectable, unify all subclasses into one
Class UnregisteredLocalFile
Currently it doesn't really work in the repository role, there are lots of functions missing. It is used by the WebStore extension in the standalone role.
File update.php
document
Member UploadBase::checkSvgScriptCallback ( $element, $attribs)
Replace this with a whitelist filter!
Member UploadStashTest::testBug29408 ()
give this test a real name explaining what is being tested here
Member User::getSkin ()
FIXME: Need to check the old failback system [AV]
Member User::passwordChangeInputAttribs ()
FIXME: This does not belong here; put it in Html or Linker or somewhere
Member User::saveOptions ()
document
Member User::saveSettings ()
Only rarely do all these fields need to be set!
Member UserrightsPage::groupCheckboxes ( $usergroups, $user)
Just pass the username string?
File Vector.php
document
Member WebInstallerOutput::getCSS ( $dir)
Possibly get rid of this function and use ResourceLoader in the manner it was designed to be used in, rather than just grabbing a list of filenames from it, and not properly handling such details as media types in module definitions.
Member wfAssembleUrl ( $urlParts)
Need to integrate this into wfExpandUrl (bug 32168)
Member wfClientAcceptsGzip ( $force=false)

document

FIXME: We may want to blacklist some broken browsers

Member wfExpandIRI ( $url)
handle punycode domains too
Member wfExpandUrl ( $url, $defaultProto=PROTO_CURRENT)
this won't work with current-path-relative URLs like "subdir/foo.html", etc.
Member wfLogProfilingData ()
document
Member wfNegotiateType ( $cprefs, $sprefs)
FIXME: Doesn't handle params like 'text/plain; charset=UTF-8' XXX: generalize to negotiate other stuff
Member wfRemoveDotSegments ( $urlPath)
Need to integrate this into wfExpandUrl (bug 32168)
Member wfShowingResults ( $offset, $limit)
document
Member WikiMap::getWikiName ( $wikiID)
We can give more info than just the wiki id!
Member WikiPage::doRollback ( $fromP, $summary, $token, $bot, &$resultDetails, User $user)
Separate the business/permission stuff out from backend code
Member WikiPage::getActionOverrides ()
Move this UI stuff somewhere else
Member WikiPage::onArticleEdit ( $title)
Verify that $title is always a Title object (and never false or null), add Title hint to parameter $title
Member WikiPage::supportsSections ()

The skin should check this and not offer section functionality if sections are not supported.

The EditPage should check this and not offer section functionality if sections are not supported.

Member WikiPageTest::broken_testDoRollback ()
FIXME: this is a better rollback test than the one below, but it keeps failing in jenkins for some reason.
Member WikiPageTest::testDoRollback ()
FIXME: the above rollback test is better, but it keeps failing in jenkins for some reason.
Member WikiReference::getLocalUrl ( $page)
FIXME: This may be generalized...
Class WikiRevision
document (e.g.
Class WordLevelDiff
document
Member Xml::isWellFormed ( $text)
Error position reporting return
Member XMPReader::parseExtended ( $content)
In serious need of testing
Class XMPTest
covers tags
Member XMPTest::testExtendedXMP ()
This is based on what the standard says. Need to find a real world example file to double check the support for this is right.