summaryrefslogtreecommitdiff
path: root/tests/phpunit/includes/RequestContextTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/phpunit/includes/RequestContextTest.php')
-rw-r--r--tests/phpunit/includes/RequestContextTest.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/phpunit/includes/RequestContextTest.php b/tests/phpunit/includes/RequestContextTest.php
index f5871716..1776b5d5 100644
--- a/tests/phpunit/includes/RequestContextTest.php
+++ b/tests/phpunit/includes/RequestContextTest.php
@@ -7,6 +7,8 @@ class RequestContextTest extends MediaWikiTestCase {
/**
* Test the relationship between title and wikipage in RequestContext
+ * @covers RequestContext::getWikiPage
+ * @covers RequestContext::getTitle
*/
public function testWikiPageTitle() {
$context = new RequestContext();
@@ -25,9 +27,11 @@ class RequestContextTest extends MediaWikiTestCase {
$context->setTitle( $curTitle );
$this->assertTrue( $curTitle->equals( $context->getWikiPage()->getTitle() ),
"When a title is updated the WikiPage should be purged and recreated on-demand with the new title." );
-
}
+ /**
+ * @covers RequestContext::importScopedSession
+ */
public function testImportScopedSession() {
$context = RequestContext::getMain();
@@ -58,7 +62,7 @@ class RequestContextTest extends MediaWikiTestCase {
$this->assertEquals( $sinfo['userId'], $context->getUser()->getId(), "Correct context user ID." );
$this->assertEquals( 'UnitTestContextUser', $context->getUser()->getName(), "Correct context user name." );
- unset ( $sc ); // restore previous context
+ unset( $sc ); // restore previous context
$info = $context->exportSession();
$this->assertEquals( $oInfo['ip'], $info['ip'], "Correct initial IP address." );