merged master
authorjeroendedauw <jeroendedauw@gmail.com>
Wed, 6 Jun 2012 14:42:18 +0000 (16:42 +0200)
committerjeroendedauw <jeroendedauw@gmail.com>
Wed, 6 Jun 2012 14:44:15 +0000 (16:44 +0200)
Change-Id: I4cf7b0f87cd571a6b50f66995dd9ad987a6ecdf8

15 files changed:
1  2 
includes/Article.php
includes/AutoLoader.php
includes/Export.php
includes/ImagePage.php
includes/LinksUpdate.php
includes/Revision.php
includes/WikiPage.php
includes/actions/RawAction.php
includes/api/ApiPurge.php
includes/specials/SpecialUndelete.php
languages/Language.php
languages/messages/MessagesEn.php
languages/messages/MessagesQqq.php
tests/phpunit/includes/filerepo/FileBackendTest.php
tests/phpunit/maintenance/DumpTestCase.php

Simple merge
Simple merge
Simple merge
Simple merge
@@@ -63,10 -65,12 +63,14 @@@ class LinksUpdate extends SqlDataUpdat
  
                $this->mTitle = $title;
                $this->mId = $title->getArticleID();
 +              assert( $this->mId > 0 );
  
+               if ( !$this->mId ) {
+                       throw new MWException( "The Title object did not provide an article ID. Perhaps the page doesn't exist?" );
+               }
                $this->mParserOutput = $parserOutput;
 +
                $this->mLinks = $parserOutput->getLinks();
                $this->mImages = $parserOutput->getImages();
                $this->mTemplates = $parserOutput->getTemplates();
Simple merge
@@@ -3197,13 -2971,6 +3193,14 @@@ class WikiPage extends Page 
                global $wgUser;
                return $this->isParserCacheUsed( ParserOptions::newFromUser( $wgUser ), $oldid );
        }
 +
 +      public function getDeletionUpdates() {
 +              $updates = $this->getContentHandler()->getDeletionUpdates( $this );
 +
 +              wfRunHooks( 'WikiPageDeletionUpdates', array( $this, &$updates ) );
 +              return $updates;
 +      }
++
  }
  
  class PoolWorkArticleView extends PoolCounterWork {
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
@@@ -313,19 -311,9 +311,21 @@@ abstract class DumpTestCase extends Med
                $this->skipWhitespace();
  
                $this->assertTextNode( "comment", $summary );
 +              $this->skipWhitespace();
 +
 +              if ( $this->xml->name == "model" ) { // model tag is optional
 +                      $this->assertTextNode( "model", CONTENT_MODEL_WIKITEXT ); //@todo: make this a test parameter
 +                      $this->skipWhitespace();
 +              }
 +
 +
 +              if ( $this->xml->name == "format" ) { // format tag is optional
 +                      $this->assertTextNode( "format", CONTENT_FORMAT_WIKITEXT ); //@todo: make this a test parameter
 +                      $this->skipWhitespace();
 +              }
  
+               $this->assertTextNode( "sha1", $text_sha1 );
                $this->assertNodeStart( "text", false );
                if ( $text_bytes !== false ) {
                        $this->assertEquals( $this->xml->getAttribute( "bytes" ), $text_bytes,