From 7d4d9016d4a57d50b8fd086d480019063e704a78 Mon Sep 17 00:00:00 2001 From: Brad Jorsch Date: Tue, 2 Feb 2016 09:27:05 -0500 Subject: [PATCH] Set title on context in ApiDocumentationTest For some reason the unit testing infrastructure doesn't set one, and that makes RequestContext warn. Bug: T125491 Change-Id: I3e0ec0f567dd06231bca0d3d923e9d4e05ef5514 --- tests/phpunit/structure/ApiDocumentationTest.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/phpunit/structure/ApiDocumentationTest.php b/tests/phpunit/structure/ApiDocumentationTest.php index d2f96dc9cb..5cf75bdfdc 100644 --- a/tests/phpunit/structure/ApiDocumentationTest.php +++ b/tests/phpunit/structure/ApiDocumentationTest.php @@ -33,6 +33,9 @@ class ApiDocumentationTest extends MediaWikiTestCase { if ( !self::$main ) { self::$main = new ApiMain( RequestContext::getMain() ); self::$main->getContext()->setLanguage( 'en' ); + self::$main->getContext()->setTitle( + Title::makeTitle( NS_SPECIAL, 'Badtitle/dummy title for ApiDocumentationTest' ) + ); } return self::$main; } -- 2.20.1