From bb2b97b39d4ef7dd2cfaf90f3199b75fc338a8c7 Mon Sep 17 00:00:00 2001 From: Chad Horohoe Date: Mon, 8 Aug 2011 16:08:48 +0000 Subject: [PATCH] Mostly revert r89400: not needed since Brion fixed the tests in other ways --- tests/phpunit/includes/BlockTest.php | 6 ++---- tests/phpunit/includes/api/ApiBlockTest.php | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/tests/phpunit/includes/BlockTest.php b/tests/phpunit/includes/BlockTest.php index cc6ed9241b..8d9044517f 100644 --- a/tests/phpunit/includes/BlockTest.php +++ b/tests/phpunit/includes/BlockTest.php @@ -5,8 +5,6 @@ */ class BlockTest extends MediaWikiLangTestCase { - const REASON = "Some reason"; - private $block, $madeAt; /* variable used to save up the blockID we insert in this test suite */ @@ -37,7 +35,7 @@ class BlockTest extends MediaWikiLangTestCase { } $this->block = new Block( 'UTBlockee', 1, 0, - self::REASON + 'Parce que' ); $this->madeAt = wfTimestamp( TS_MW ); @@ -68,7 +66,7 @@ class BlockTest extends MediaWikiLangTestCase { // $this->dumpBlocks(); $this->assertTrue( $this->block->equals( Block::newFromTarget('UTBlockee') ), "newFromTarget() returns the same block as the one that was made"); - + $this->assertTrue( $this->block->equals( Block::newFromID( $this->blockId ) ), "newFromID() returns the same block as the one that was made"); } diff --git a/tests/phpunit/includes/api/ApiBlockTest.php b/tests/phpunit/includes/api/ApiBlockTest.php index 227555ebf1..91fb146d44 100644 --- a/tests/phpunit/includes/api/ApiBlockTest.php +++ b/tests/phpunit/includes/api/ApiBlockTest.php @@ -46,7 +46,7 @@ class ApiBlockTest extends ApiTestCase { $data = $this->doApiRequest( array( 'action' => 'block', 'user' => 'UTBlockee', - 'reason' => BlockTest::REASON, + 'reason' => 'Some reason', 'token' => $pageinfo['blocktoken'] ), $data ); $block = Block::newFromTarget('UTBlockee'); -- 2.20.1