r79378 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r79377‎ | r79378 | r79379 >
Date:22:34, 31 December 2010
Author:soxred93
Status:ok
Tags:
Comment:
Forgot to change the other API tests
Modified paths:
  • /trunk/phase3/tests/phpunit/includes/api/ApiWatchTest.php (modified) (history)

Diff [purge]

Index: trunk/phase3/tests/phpunit/includes/api/ApiWatchTest.php
@@ -15,8 +15,8 @@
1616 function testLogin() {
1717 $data = $this->doApiRequest( array(
1818 'action' => 'login',
19 - 'lgname' => self::$sysopUser->userName,
20 - 'lgpassword' => self::$sysopUser->password ) );
 19+ 'lgname' => $this->sysopUser->userName,
 20+ 'lgpassword' => $this->sysopUser->password ) );
2121
2222 $this->assertArrayHasKey( "login", $data[0] );
2323 $this->assertArrayHasKey( "result", $data[0]['login'] );
@@ -26,8 +26,8 @@
2727 $data = $this->doApiRequest( array(
2828 'action' => 'login',
2929 "lgtoken" => $token,
30 - "lgname" => self::$sysopUser->userName,
31 - "lgpassword" => self::$sysopUser->password ), $data );
 30+ "lgname" => $this->sysopUser->userName,
 31+ "lgpassword" => $this->sysopUser->password ), $data );
3232
3333 $this->assertArrayHasKey( "login", $data[0] );
3434 $this->assertArrayHasKey( "result", $data[0]['login'] );
@@ -38,7 +38,7 @@
3939 }
4040
4141 function testGettingToken() {
42 - foreach ( array( self::$user, self::$sysopUser ) as $user ) {
 42+ foreach ( array( $this->user, $this->sysopUser ) as $user ) {
4343 $this->getUserTokens( $user );
4444 }
4545 }
@@ -79,7 +79,7 @@
8080 }
8181
8282 function testGetToken() {
83 - return $this->getUserTokens( self::$sysopUser );
 83+ return $this->getUserTokens( $this->sysopUser );
8484 }
8585
8686 /**

Status & tagging log