From: Platonides Date: Sat, 9 Feb 2013 18:57:03 +0000 (+0100) Subject: testInvalidEmail() passes now without local config X-Git-Tag: 1.31.0-rc.0~20516^2 X-Git-Url: http://git.cyclocoop.org/url?a=commitdiff_plain;h=d962a0be6412caacf84811d89801fdce071ea8c2;p=lhc%2Fweb%2Fwiklou.git testInvalidEmail() passes now without local config ApiAccountCreationTest::testInvalidEmail() no longer needs LocalSettings to have $wgEnableEmail = true; Change-Id: I97803be116fda8194e46fe0021c7b32d7b703b1d --- diff --git a/tests/phpunit/includes/api/ApiAccountCreationTest.php b/tests/phpunit/includes/api/ApiAccountCreationTest.php index f37e2799da..94082e5aff 100644 --- a/tests/phpunit/includes/api/ApiAccountCreationTest.php +++ b/tests/phpunit/includes/api/ApiAccountCreationTest.php @@ -9,6 +9,7 @@ class ApiCreateAccountTest extends ApiTestCase { function setUp() { parent::setUp(); LoginForm::setCreateaccountToken(); + $this->setMwGlobals( array( 'wgEnableEmail' => true ) ); } /** @@ -141,10 +142,6 @@ class ApiCreateAccountTest extends ApiTestCase { * @expectedException UsageException */ function testInvalidEmail() { - global $wgEnableEmail; - if ( !$wgEnableEmail ) { - $this->markTestSkipped( 'email is not enabled, so createaccount does not check it' ); - } $this->doApiRequest( array( 'action' => 'createaccount', 'name' => 'Test User',